XBMC Community Forum
[Windows] AudioEngine testers - Windows platform only - Printable Version

+- XBMC Community Forum (http://forum.xbmc.org)
+-- Forum: Development (/forumdisplay.php?fid=32)
+--- Forum: Development (/forumdisplay.php?fid=93)
+--- Thread: [Windows] AudioEngine testers - Windows platform only (/showthread.php?tid=124600)



RE: [Windows] AudioEngine testers - Windows platform only - jpsdr - 2012-05-15 21:40

(2012-05-15 21:15)DDDamian Wrote:  Check into EDID issues and resolve those.
Huh
Wich means ?
Sorry, i'm totaly lost here. Can you tell me what i have to do ? (Or a link wich will explain to me what i have to do ?).

I've also trouble to understand what seems to be (at least for me) contradictory informations.
- You said that if moninfo can't detect it, either you. But the device is present in Wasapi and Windows.
- You said information show only 2 channels possibility, but i've configured 7.1 in both Windows and XBMC, and XBMC played correctly 5.1 files, either pathrough (DTS), or not (FLAC).
Finaly, all of these made me totaly confused...


RE: [Windows] AudioEngine testers - Windows platform only - bambi73 - 2012-05-15 22:17

(2012-05-15 18:26)DDDamian Wrote:  
(2012-05-14 22:39)bambi73 Wrote:  today I compiled xbmc master and got no audio, completelly nothing, not even skin sounds.
...

Hi there - the log shows WASAPI is initializing correctly, but I don't see where you try to play something, so not sure what happens when you do. I would need a log where you actually attempt to play something. I would recommend with WASAPI. Thx.

I mean it don't do any sound, not even "bubble sound" from skin. Of course I tried to play some video files, with same (bad) result.
There is with debug log where I tried to play some playback.
Thx

EDIT: Ufff, please ignore both posts Smile. My skin doesn't show scroll bar in settings and so I missed Audio output device option.
Never thought that there is something under all these greyed out toggles Confused
Case solved, but maybe you should move this quite important option bit higher in list.


RE: [Windows] AudioEngine testers - Windows platform only - DDDamian - 2012-05-15 22:59

@bambi - i totally agree - we're looking at the best way to implement the gui settings.


RE: [Windows] AudioEngine testers - Windows platform only - DDDamian - 2012-05-15 23:22

(2012-05-15 21:40)jpsdr Wrote:  
(2012-05-15 21:15)DDDamian Wrote:  Check into EDID issues and resolve those.
Huh
Wich means ?
Sorry, i'm totaly lost here. Can you tell me what i have to do ? (Or a link wich will explain to me what i have to do ?).

I've also trouble to understand what seems to be (at least for me) contradictory informations.
- You said that if moninfo can't detect it, either you. But the device is present in Wasapi and Windows.
- You said information show only 2 channels possibility, but i've configured 7.1 in both Windows and XBMC, and XBMC played correctly 5.1 files, either pathrough (DTS), or not (FLAC and AAC).
- You AE can't decode AAC yet. Nevertheless, i've been able to play 5.1 and 2.0 AAC files, with and without the "Device can process AAC" option checked.

Finaly, all of these made me totaly confused...

Most of what you're asking above, and all along, has to do with the detection of channels. You have an HDMI device which is only reporting two channels. If you are plugged into a TV that's fine, with a receiver it should report more. That's why I asked for the MonInfo report, which isn't reporting anything about your audio device at the end of the HDMI connection. It should report the device's audio capabilities, which is far different from "the device is present in Wasapi and Windows" Yes, it is present, and reports two channels.

Passthrough is not dependent on the channel settings, it is "passed through" as is, encoded as it originally was, which is why it plays fine even though channels detected are only two.

Typically this is due to EDID issues as mentioned. Frankly I don't care to be the google-bitch here (as some of the devs call it). Feel free to though. I've pointed you in the right direction several times here, fixed your issues, then got an "I don't like it", so you're on your own there.

The AAC button does nothing at this point. As mentioned earlier "AAC will not play unless your device decodes it natively. If it's playing then obviously it does.


RE: [Windows] AudioEngine testers - Windows platform only - jayhawk785 - 2012-05-15 23:34

DDDamian-

Issue of xbmc recovering when the associated wasapi device is turned off seems to be fixed. However, my processor goes up to about 30% and stays there while it tries to reconnect hundreds of thousands of times. I'm not certain if others have mentioned it, but thought I'd post in here to get your take. I didnt see any mention of it in this thread since the end of april (well before merge).

Code:
15:38:00 T:4212   ERROR: CAESinkWASAPI::AddPackets: GetBuffer failed due to AUDCLNT_E_DEVICE_INVALIDATED
15:38:00 T:4280  NOTICE: VideoInfoScanner: Finished scan. Scanning for video info took 00:05
15:38:00 T:4212   ERROR: CAESinkWASAPI::AddPackets: GetBuffer failed due to AUDCLNT_E_DEVICE_INVALIDATED
15:38:00 T:5716   ERROR: Previous line repeats 1911 times.
15:38:00 T:5716  NOTICE: Thread Background Loader start, auto delete: false
15:38:00 T:4212   ERROR: CAESinkWASAPI::AddPackets: GetBuffer failed due to AUDCLNT_E_DEVICE_INVALIDATED
16:19:22 T:3120   ERROR: Previous line repeats 94731218 times.
16:19:22 T:3120  NOTICE: Thread Jobworker start, auto delete: true
16:19:22 T:4212   ERROR: CAESinkWASAPI::AddPackets: GetBuffer failed due to AUDCLNT_E_DEVICE_INVALIDATED
16:19:22 T:5820   ERROR: Previous line repeats 9693 times.
16:19:22 T:5820  NOTICE: Thread CFileCache start, auto delete: false
16:19:22 T:4212   ERROR: CAESinkWASAPI::AddPackets: GetBuffer failed due to AUDCLNT_E_DEVICE_INVALIDATED
16:19:23 T:5312   ERROR: Previous line repeats 27113 times.
16:19:23 T:5312  NOTICE: Thread CFileCache start, auto delete: false
16:19:23 T:4212   ERROR: CAESinkWASAPI::AddPackets: GetBuffer failed due to AUDCLNT_E_DEVICE_INVALIDATED
16:19:23 T:2372   ERROR: Previous line repeats 5463 times.
16:19:23 T:2372  NOTICE: Thread CFileCache start, auto delete: false
16:19:23 T:4212   ERROR: CAESinkWASAPI::AddPackets: GetBuffer failed due to AUDCLNT_E_DEVICE_INVALIDATED
16:19:25 T:5384   ERROR: Previous line repeats 80981 times.
16:19:25 T:5384  NOTICE: Thread Background Loader start, auto delete: false
16:19:25 T:4212   ERROR: CAESinkWASAPI::AddPackets: GetBuffer failed due to AUDCLNT_E_DEVICE_INVALIDATED

I can probably get a debug log if that will help--just figured you may have already seen this at some point and have an answer or hopefully a solution in the works Smile

thanks!


RE: [Windows] AudioEngine testers - Windows platform only - DDDamian - 2012-05-15 23:55

Hi jayhawk - replied in the other thread, but yep - I need to fix that for sure - thanks for pointing it out - easy fix Smile


RE: [Windows] AudioEngine testers - Windows platform only - jpsdr - 2012-05-16 00:21

(2012-05-15 23:22)DDDamian Wrote:  Passthrough is not dependent on the channel settings, it is "passed through" as is, encoded as it originally was, which is why it plays fine even though channels detected are only two.
I know what passthrough is, but also non passthrough (FLAC) is played in 5.1.

(2012-05-15 23:22)DDDamian Wrote:  The AAC button does nothing at this point. As mentioned earlier "AAC will not play unless your device decodes it natively. If it's playing then obviously it does.
Ok.

Little question : Is DTS-HD MA supported on passthrough ? If i ask, it's only because i have a file with DTS-HD MA (well, at least it's what's xbmc said when i ask codec info), but my receiver isn't displaying "DTS-HD MA" as it usualy does when i play Blu-Ray with DTS-HD MA.
So either it's not supported, either it's still the same EDID issue...
Google search doesn't give me true results (hard to search in an ocean)... Except that if it's the receiver wich is wrong, i'm screwed unless Pioneer update the FW.... I don't beleived on it. If it's the nvidia drivers... a little hope...


RE: [Windows] AudioEngine testers - Windows platform only - DDDamian - 2012-05-16 00:41

@jpsdr - yes DTS-HDMA is supported. Your driver has to support it. If you right-click on the speaker icon in the right side of the taskbar, select Playback Devices, and on the HDMI device select properties, it will show you the supported formats. If DTS-HD is in there it will play DTS-MA.


RE: [Windows] AudioEngine testers - Windows platform only - jpsdr - 2012-05-16 10:25

@DDDamian

First, i must appologise for a not very nice behavior. I must have thank you for your time and help me solved problem instead of a simple "i don't like it".

I'll nevertheless explain why i've been a little upset, about my problem of VIA vs nVidia.
I've got no problem with DirectSound when i was under Windows XP.
After upgrading to Windows7 (after you've telling me a lot of time to do this to have the behavior i wanted), i've got no problem with either DirectSound or Wasapi with all builds and the last build i've done (and keeping for now), by chance, just just before the merge of the new AE.
Suddenly, with the new AE, there is a problem of the VIA highjacking the nVidia with Wasapi... For me, there is an issue in the AE, and not on my end. I would have got the problem since the upgrade to Windows 7 (even on the situation of only Wasapi and not DirectSound) with both versions, it may have been a problem on my end, but in this situation, i don't think it is. So, telling me that the problem is in my end the solution is to disable VIA, period ! .... Undecided
If you had said that, for now, this is the fix, this problem is not a priority (as i have a fix), i would not have react like that.

But my question is : What's your statement about it ?
From my point of view, resuming :
- No issues with Directsound under Windows XP.
- No issues with either DirectSound or Wasapi under Windows 7 before new AE.
- Issues after merge of the new AE.
=> Problem is not on my end, but with something on the new AE.
Now, if you think otherwise, i would like a little explaination of "why".

(2012-05-16 00:41)DDDamian Wrote:  @jpsdr - yes DTS-HDMA is supported. Your driver has to support it. If you right-click on the speaker icon in the right side of the taskbar, select Playback Devices, and on the HDMI device select properties, it will show you the supported formats. If DTS-HD is in there it will play DTS-MA.
It reports DTS-HD. But, I've done this (before reading this post) indeed to check something else, and to go back to another hot subject, it also reports 8 supported audio channels...Big Grin

Is there any debug log code i could had somewhere (maybe trace the raw data from EDID or others things) to help trace to find out why xbmc detect only 2 channels when everyone else seems to detect more...

As i don't know the specs, the following may be stupid questions, but, if xbmc read EDID, are devices :
- Report all the supported numbers audio channels or only the maximum ?
- If they report more than one information, is it supposed to have a specific order ?
- Can the informations be mixed (in a total mess), or are they packed (for exemple all sampling rates are in the same packet, you can't have an audio format mixed in the middle).
I'm asking about only and only the specs, not the usual behavior devices may have.


RE: [Windows] AudioEngine testers - Windows platform only - DDDamian - 2012-05-16 17:26

@jpsdr - if you wish to re-enable the VIA onboard go ahead - just make sure you select the device you wish to use in both Win and XBMC - AE really doesn't care what device you use, as long as it responds.

If we are talking about the problem being why 2-channels is reported as the max for that card for pcm streams, here's the "why" or how it works:

- Windows reads the EDID data supplied by the device to determine it's capabilities and whether it is actively connected and on
- it only exposes a subset of the EDID data in the registry (unfortunately) so we still have to directly query it for additional data
- this additional data comes from the driver, and is queried via a common WASAPI function called IsFormatSupported()
- to determine your devices' capabilities we ping IsFormatSupported() with various data blocks representing different formats, sample rates, channel counts
- the driver responds with whether or not that particular format/ sample rate/ channel layout is supported
- we do this twice, once at startup for all reported devices, and again just before playback for that specific format
- if IsFormatSupported() returns true, we report it as part of the device capabilites during the device enumeration at start-up (as shown in your log)
- if you are about to play something we ping it again with the stream's format for the selected device
- if IsFormatSupported() returns true in that case, we proceed to try initialize the device with that format. It is not unknown for some mis-behaving devices to report that a format is supported then fails to initialize - the opposite can happen too. I would not expect this to occur with a fairly modern, widespread device like your GT520
- in the case of channels supported, we iterate down from the maximum AE channel count (21 for Windows) to zero until we get a positive response. In your case this should happen when we hit 8 channels - that is what your card supports and it should return true
- if the maximum reported channels is greater than 2.1 we flag it as supporting AE_FMT_LPCM - our shorthand for "Receiver supports multichannel LPCM" as seen in the settings page, although your selection on that page is the determining factor for that support

Your device driver is reporting 2 channels as the maximum it will accept for pcm data, which is incorrect.

Here is a link to my log - you will see near the start that my HDMI device reports 8 channels, and is thus flagged as supporting AE_FMT_LPCM in it's supported formats, among others. See device #3. I briefly play a 5.1 pcm further down.

Here is my EDID report from MonInfo, showing the audio capabilities reported over HDMI, mirroring the same info.

This begs the question: are you using nVidia's most recent drivers? Or a generic Windows driver or old nVidia driver?

I pointed out that EDID data can be missing as some manufacturers did not follow the standard. I find it hard to believe that you couldn't find results on Google - I typed in EDID plus my receiver's model number and got dozens of hits. Tulli over at avsforums is the guru on EDID - just to be the google-bitch here's a link: http://www.avsforum.com/avs-vb/showthread.php?t=1227161