List Info

Thread: video pausing when using a window created by pyGTK




video pausing when using a window created by pyGTK
country flaguser name
United States
2007-02-20 18:08:07
hi all,

   I'm updating pyplayer (python bindings) to work with
atlas (HEAD) all_defines.   When playing video, if the
window was created using m_pSiteWindowed->Create(NULL,
style)
playback works great.  When attaching to a window created
with pyGtk the video will pause, skip ahead, play for a few
seconds, and then repeat.
audio playback does not skip at all.  

XInitThreads() is called before the window is created. 
Before adding this the engine segfaulted as soon as playback
started.


I looked at the gtk player briefly and didnt see anything
much different from pyplayer other than capturing xevents
and passing them to the engine.   
i wasn't sure if this would affect performance, or was just
there to handle resizing and movement of the window.

any ideas?

-- 
Peter Krenesky
Analyst Programmer
Open Source Lab  OSU
email: peterosuosl.org
office: 541-737-9572

_______________________________________________
Player-dev mailing list
Player-devhelixcommunity.org
http://lists.helixcommunity.org/mailman/listinfo/play
er-dev

Re: video pausing when using a window created by pyGTK
country flaguser name
United States
2007-02-21 18:04:07
At 04:08 PM 2/20/2007, Peter Krenesky wrote:
>hi all,
>
>    I'm updating pyplayer (python bindings) to work with
atlas (HEAD) 
> all_defines.   When playing video, if the window was
created using 
> m_pSiteWindowed->Create(NULL, style)
>playback works great.  When attaching to a window
created with pyGtk the 
>video will pause, skip ahead, play for a few seconds,
and then repeat.
>audio playback does not skip at all.
>
>XInitThreads() is called before the window is created. 
Before adding this 
>the engine segfaulted as soon as playback started.


Edgard Lima had the problem last year too, but
unfortunately, the solution 
wasn't posted back to the mailing list.



I'm just tossing out two ideas here...

(1) Could it be that GDK's automatic double-buffering is
getting in the way?

Disabling automatic double buffering:
static void
my_widget_init (MyWidget *widget)
{
     ...
     GTK_WIDGET_UNSET_FLAGS (widget, GTK_DOUBLE_BUFFERED);
     ...
}
http://primates.ximian.com/~federico/misc/
gtk-drawing-model/index.html

Or:
static void
your_video_area_realized_signal_handler(GtkWidget *widget,
HXPlayer *player)
{
     gtk_widget_set_double_buffered(widget, FALSE)
}


(2) If the above didn't work, could you check if
GtkWidgetFlags 
GTK_APP_PAINTABLE flag for the relevant (drawing area)
widget is set?

gtk_widget_set_app_paintable(GTK_WIDGET(widget), TRUE);

Thanks.


-- 
Daniel Yek



>I looked at the gtk player briefly and didnt see
anything much different 
>from pyplayer other than capturing xevents and passing
them to the engine.
>i wasn't sure if this would affect performance, or was
just there to 
>handle resizing and movement of the window.
>
>any ideas?
>
>--
>Peter Krenesky
>Analyst Programmer
>Open Source Lab  OSU
>email: peterosuosl.org
>office: 541-737-9572


_______________________________________________
Player-dev mailing list
Player-devhelixcommunity.org
http://lists.helixcommunity.org/mailman/listinfo/play
er-dev

Re: video pausing when using a window created by pyGTK
country flaguser name
United States
2007-02-21 18:04:07
At 04:08 PM 2/20/2007, Peter Krenesky wrote:
>hi all,
>
>    I'm updating pyplayer (python bindings) to work with
atlas (HEAD) 
> all_defines.   When playing video, if the window was
created using 
> m_pSiteWindowed->Create(NULL, style)
>playback works great.  When attaching to a window
created with pyGtk the 
>video will pause, skip ahead, play for a few seconds,
and then repeat.
>audio playback does not skip at all.
>
>XInitThreads() is called before the window is created. 
Before adding this 
>the engine segfaulted as soon as playback started.


Edgard Lima had the problem last year too, but
unfortunately, the solution 
wasn't posted back to the mailing list.



I'm just tossing out two ideas here...

(1) Could it be that GDK's automatic double-buffering is
getting in the way?

Disabling automatic double buffering:
static void
my_widget_init (MyWidget *widget)
{
     ...
     GTK_WIDGET_UNSET_FLAGS (widget, GTK_DOUBLE_BUFFERED);
     ...
}
http://primates.ximian.com/~federico/misc/
gtk-drawing-model/index.html

Or:
static void
your_video_area_realized_signal_handler(GtkWidget *widget,
HXPlayer *player)
{
     gtk_widget_set_double_buffered(widget, FALSE)
}


(2) If the above didn't work, could you check if
GtkWidgetFlags 
GTK_APP_PAINTABLE flag for the relevant (drawing area)
widget is set?

gtk_widget_set_app_paintable(GTK_WIDGET(widget), TRUE);

Thanks.


-- 
Daniel Yek



>I looked at the gtk player briefly and didnt see
anything much different 
>from pyplayer other than capturing xevents and passing
them to the engine.
>i wasn't sure if this would affect performance, or was
just there to 
>handle resizing and movement of the window.
>
>any ideas?
>
>--
>Peter Krenesky
>Analyst Programmer
>Open Source Lab  OSU
>email: peterosuosl.org
>office: 541-737-9572


_______________________________________________
Player-dev mailing list
Player-devhelixcommunity.org
http://lists.helixcommunity.org/mailman/listinfo/play
er-dev

[1-3]

about | contact  Other archives ( Real Estate discussion Medical topics )