OiO.lk Community platform!

Oio.lk is an excellent forum for developers, providing a wide range of resources, discussions, and support for those in the developer community. Join oio.lk today to connect with like-minded professionals, share insights, and stay updated on the latest trends and technologies in the development field.
  You need to log in or register to access the solved answers to this problem.
  • You have reached the maximum number of guest views allowed
  • Please register below to remove this limitation

Difference between two IAudioClient::Initialize return values

  • Thread starter Thread starter MieszkoPasierbek
  • Start date Start date
M

MieszkoPasierbek

Guest
I'm having trouble understanding the documentation for the IAudioClient initialization function. https://learn.microsoft.com/en-us/w...client/nf-audioclient-iaudioclient-initialize

It's about the difference return values;

Code:
E_INVALIDARG

and

Code:
AUDCLNT_E_UNSUPPORTED_FORMAT

The E_INVALIDARG description says "Parameter pFormat points to an invalid format description".

However, in the description AUDCLNT_E_UNSUPPORTED_FORMAT "The audio engine (shared mode) or audio endpoint device (exclusive mode) does not support the specified format."

What does it mean in E_INVALIDARG that the description format is "invalid"? I guess it's not that it doesn't fit the device, since it's already handled by AUDCLNT_E_UNSUPPORTED_FORMAT?

And it's also not that it is pFormat == NULL, since it's already handled by E_POINTER

So what specific cases does this pFormat incorrectness is covered when return == E_INVALIDARG?
<p>I'm having trouble understanding the documentation for the IAudioClient initialization function.
<a href="https://learn.microsoft.com/en-us/w...client/nf-audioclient-iaudioclient-initialize" rel="nofollow noreferrer">https://learn.microsoft.com/en-us/w...client/nf-audioclient-iaudioclient-initialize</a></p>
<p>It's about the difference return values;</p>
<pre><code>E_INVALIDARG
</code></pre>
<p>and</p>
<pre><code>AUDCLNT_E_UNSUPPORTED_FORMAT
</code></pre>
<p>The E_INVALIDARG description says "Parameter pFormat points to an <strong>invalid format description</strong>".</p>
<p>However, in the description AUDCLNT_E_UNSUPPORTED_FORMAT "The audio engine (shared mode) or audio endpoint device (exclusive mode) <strong>does not support the specified format</strong>."</p>
<p>What does it mean in E_INVALIDARG that the description format is "invalid"? I guess it's not that it doesn't fit the device, since it's already handled by AUDCLNT_E_UNSUPPORTED_FORMAT?</p>
<p>And it's also not that it is <code>pFormat == NULL</code>, since it's already handled by E_POINTER</p>
<p>So what specific cases does this pFormat incorrectness is covered when <code>return == E_INVALIDARG</code>?</p>
Continue reading...
 

Latest posts

A
Replies
0
Views
1
Alfredo Augusto Petri
A
Top