[Vala] Binding problem or ClutterGst problem or my problem?
- From: Brian Duffy <brduffy gmail com>
- To: vala-list <vala-list gnome org>, clutter-app-devel-list clutter-project org
- Subject: [Vala] Binding problem or ClutterGst problem or my problem?
- Date: Fri, 6 Jan 2012 10:02:02 -0500
Hello,
Having trouble figuring out why I can't use set_seek_flags(...) on a
ClutterGst VideoTexture. I'm getting the error "set_seek_flags" does not
exist in the context of ClutterGst.VideoTexture. I have confirmed I'm using
Clutter-Gst 1.4.4 with ClutterGst.Version.check(1,4,4). Also, I am using
Vala 0.14 on Fedora 16. Could this be a Vala binding problem? Here is the
code ...
using Clutter;
using Gst;
using ClutterGst;
class Gui {
private VideoTexture tx;
private Stage stage;
public Gui() {
stage = new Stage();
//stage.get_default ();
stage.color = Color () { alpha = 255 };
//stage.set_fullscreen(true);
stage.set_size(1280, 720);
stage.hide.connect (Clutter.main_quit);
tx = new ClutterGst.VideoTexture();
tx.set_seek_flags(ClutterGst.SeekFlags(1));
stage.add(tx);
tx.set_reactive(true);
tx.button_press_event.connect(button_press);
tx.set_uri("file:///home/brian/Downloads/louis.mp4");
tx.set_progress(0.601732);
tx.set_playing(true);
stage.show_all();
}
private bool button_press (ButtonEvent event) {
if (tx.get_playing() == true) {
tx.set_playing(false);
stdout.printf("%f", tx.get_progress());
}else{
tx.set_playing(true);
}
return true;
}
}
void main (string[] args) {
Clutter.init(ref args);
Gst.init(ref args);
bool version = ClutterGst.Version.check(1,4,4);
if (version) {
print ("true");
}else{
print ("false");
}
var gui = new Gui();
Clutter.main();
}
//valac -g --pkg clutter-1.0 --pkg gstreamer-0.10 --pkg
gstreamer-interfaces-0.10 --pkg clutter-gst-1.0 g_test.vala
--
Duff
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]