robw
unread,Dec 30, 2008, 7:03:52 PM12/30/08Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to gstreamer-java
Hi,
sorry for another nooby question:
still making first steps with gstreamer, before I want to go on with
video and effects, i wanted to set up a basic audio-player. Using
playbin as in the tutorials works fine, but I'd like to make a custom
pipeline. Here's what I tried according to the examples from the
repository:
import org.gstreamer.Element;...
/**class to set up an own pipeline for playing audio-files**/
public class MyAudioPipePlayer {
public static void main(String[] args){
//handle no file situation with msg + exit
if(args.length<1){
System.out.println("start with path to audiofile as argument!");
System.exit(0);
}
args = Gst.init("AudioPipeline", args);
Pipeline pipe = new Pipeline("AudioPipeline");
Element src = ElementFactory.make("filesrc", "source");
//beeing unsure if the set-method is right, I also
tried
//"((FileSrc)src).setLocation(args[0]);" which changed
nothing (appearently)
src.set("location", args[0]);
Element sink = ElementFactory.make("alsasink", "output");
pipe.addMany(src, sink);
src.link(sink);
pipe.setState(State.PLAYING);
Gst.main();
pipe.setState(State.NULL);
}
}
I get the following error message in eclipse:
"(AudioPipeline:31211): GStreamer-CRITICAL **:
gst_clock_set_calibration: assertion `internal <=
gst_clock_get_internal_time (clock)' failed
"
I am still working through the gstreamer aplication development
manual, but the chapter on clocks didn't really help me...
another question: where can I find information on the names of the
specific elements for the java binding. what I mean is, I figured out
from the examples in the repository that i can use "fakesrc" and
"filesrc", "audioresample" or "audioconvert" as params, when creating
elemets with ElementFactory.make(...); is there a list, which string
names are available and what element they correspond to? I didn't find
something in the api on that..
thanks a lot for any hints for the clock problem and/or where I can
find the needed information!
happy 2009!
rob