[gst-devel] gstreamer in a game

in7y118 at public.uni-hamburg.de in7y118 at public.uni-hamburg.de
Mon Sep 29 07:52:24 CEST 2003


Hi Laurent,

I think this is certainly possible. Though it probably requires a bit of 
hacking to get all the elements working as expected.

I'm actually writing on a gaming lib for sprite based games (It should work for 
Tetris, Pacman and Bomberman as those are the ones I want - though I think even 
Super Mario, Breakout or R-Type style games should be possible.) myself as a 
side project and am determined to use GStreamer whenever I get around adding 
sound.

Your idea is pretty much like I'd use it, too:
- Have some pipeline parts on the left that provide sounds (or even music) as 
needed or "no sound" else.
- Have one big mixer/adder element, that mixes all those sounds together and 
connect that to an output.

I'd probably preload samples into some buffer via a pipeline and then use a 
source element that reads from memory instead of decoding the stuff every time. 
Though all of that would need to be written.
But if yoou were willing to spend some time on getting the missing 
infrastructure pieces put together, that would be great.

Benjamin



Quoting laurent belmonte <laurent.belmonte at aliacom.fr>:

> hi,
> 
> I am working on a game named monkey-bubble
> (http://monkey-bubble.tuxfamily.org). I want to use gstreamer for the
> sound effects and for the music. Someone have an idea how to use
> gstreamer to do this :
> play one to six samples in the same time ( same or different samples)
> 
> multiplefilesrc | queue |__
> 	  		     \
> multiplefilesrc | queue |__ \_
>                            \__ 
> multiplefilesrc | queue |_____  mixer --> oss
>                             __
> multiplefilesrc | queue |__/ _
>                             /
> multiplefilesrc | queue |__/
> 
> 
> is it feasable ?
>




More information about the gstreamer-devel mailing list