<div dir="ltr">Tim,<br>I followed your suggestions ... got playbin and used its volume property. I also created a separate thread for running the gst loop and checking bus messages and so far things are good. <br>Thanks for your help. <br>
<br>Thanks Ajay, Eric for your suggestions too. <br><br>regards,<br>raj<br><br>Thanks for your responses. Sorry for getting back so late ... just in from vacation...<br><br><i>>For stream volume control you should use playbin's "volume" property.<br>
>The GStreamer mixer interface (GstMixer) is to control hardware mixer<br>
>levels, you usually don't want that in a playback application. It's also<br>
>not very nice to use. If you don't use playbin, add a volume element to<br>
>your pipeline (alternatively: audiosinks which support stream volumes<br>
>will also have a "volume" property).<br></i><br><span><span></span></span>Does this allow volume changing when the pipeline is playing .. if so how would you do that ?<br><br><br>
<br><br><div class="gmail_quote">On Mon, Sep 1, 2008 at 3:05 AM, Tim-Philipp Müller <span dir="ltr"><<a href="mailto:t.i.m@zen.co.uk" target="_blank">t.i.m@zen.co.uk</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div>On Thu, 2008-08-28 at 13:08 -0500, Raj Swaminathan wrote:<br>
<br>
Hi,<br>
<br>
> I am new to Glib programming and gstreamer. I am trying to build a<br>
> basic media player application. So far i have gstreamer pipelines up<br>
> and rendering various media formats.<br>
<br>
</div>For a media player you'll probably want to use playbin (or even<br>
playbin2) from gst-plugins-base. There's no need to create your own<br>
pipelines.<br>
<br><div><br>
<br>
> 1) Im trying to reference the gstalsamixer plugin for volume control<br>
> and muting. I understand its an interface and im trying to find out<br>
> whats the best way to access the interface methods like<br>
> gst_alsa_alsa_mixer_get_volume etc ...<br>
> Could somebody please provide a code snippet that can show this ?<br>
<br>
</div>For stream volume control you should use playbin's "volume" property.<br>
The GStreamer mixer interface (GstMixer) is to control hardware mixer<br>
levels, you usually don't want that in a playback application. It's also<br>
not very nice to use. If you don't use playbin, add a volume element to<br>
your pipeline (alternatively: audiosinks which support stream volumes<br>
will also have a "volume" property).<br>
<div><br>
<br>
> 2) When designing the media player, whats the best way to accept user<br>
> input. Do i spool a separate thread for rendering media while the main<br>
> thread waits for user input or is there a better way within gstreamer<br>
> to do this?<br>
<br>
</div>GStreamer does all its playback in threads of its own anyway, so the<br>
main thread is yours. All you need to do is check the<br>
pipeline's/playbin's GstBus for messages (errors, tags, state changes)<br>
from time to time.<br>
<br>
Cheers<br>
<font color="#888888"> -Tim<br>
</font><div><div></div><div><br>
<br>
<br>
<br>
-------------------------------------------------------------------------<br>
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge<br>
Build the coolest Linux based applications with Moblin SDK & win great prizes<br>
Grand prize is a trip for two to an Open Source event anywhere in the world<br>
<a href="http://moblin-contest.org/redirect.php?banner_id=100&url=/" target="_blank">http://moblin-contest.org/redirect.php?banner_id=100&url=/</a><br>
_______________________________________________<br>
gstreamer-devel mailing list<br>
<a href="mailto:gstreamer-devel@lists.sourceforge.net" target="_blank">gstreamer-devel@lists.sourceforge.net</a><br>
<a href="https://lists.sourceforge.net/lists/listinfo/gstreamer-devel" target="_blank">https://lists.sourceforge.net/lists/listinfo/gstreamer-devel</a><br>
</div></div></blockquote></div><br></div>