audio mixing within cef ?

Do not post support requests, bug reports or feature requests. Discuss CEF here. Non-CEF related discussion goes in General Discussion!

audio mixing within cef ?

Postby tgayet » Wed May 29, 2019 11:00 am

Hello,

I am currently working with CEF in screenless mode (OnScreenRendering), I know how to grabr the buffers resulting from images via the callback onPaint().

Regarding audio, I recently saw the following interface: https://bitbucket.org/chromiumembedded/ ... paths.gypi which defines an audio_stream_id for each audio element.

According to the tests carried out, each audio element has a separate identifier (1, 2, ...) but no mixing is done. In parallel, we see that audio pulse under linux also receives the flows in parallel and does the mix.

Is there a way already implemented that would allow CEF to do this mix of internal audio streams of the html page.

Indeed, the mechanism of callback for the audio as actually implemented is interesting but I thought to find the same mechanism as for the image, namely a global rendering and thus for the audio a mixture. Instead, each audio is separated by audio object instance.

So my question is whether a mix of CEF internal audio already exists or if you have to do it yourself with ffmpeg, gstreamer, ...

Thank you in advance for your answer.

Thierry
tgayet
Techie
 
Posts: 27
Joined: Wed Apr 24, 2019 6:53 am

Re: audio mixing within cef ?

Postby jgh » Sun Jul 14, 2019 10:49 am

mixing audio is pretty easy, all you really have to do is sum the samples. the trick is making sure you line your streams up properly with the timestamps.
jgh
Techie
 
Posts: 16
Joined: Sun Jul 14, 2019 10:38 am


Return to CEF Discussion

Who is online

Users browsing this forum: No registered users and 19 guests