Impresario
Posts: 14
Joined: Sun May 31, 2015 3:50 am

Controlling omxplayer with a tkinter app

Tue Nov 07, 2017 10:14 pm

With help from members of this forum I managed to initiate omxplayer from a python app and am able to send controlling keystrokes to omxplayer. For testing purposes, the keystrokes are predetermined and issued after varying time delays from the python app.

For a real-world app, i would like to use tkinter to paint start, stop, pause, etc symbols overlaying the omxplayer display.so that a used can control the action from the touch-screen. I've not found a way to have my python app in front of the omxplayer window. I tried various parameters for omxplayer and tkinter without success.

Any suggestions would be most appreciated.

jehutting
Posts: 143
Joined: Sun Feb 15, 2015 8:37 am
Location: The Netherlands

Re: Controlling omxplayer with a tkinter app

Wed Nov 08, 2017 3:59 am

Omxplayer has a '--layer' option which you can use to change the dispmanx layer to 'show' the video on. For omxplayer the default layer is layer 0.

The dispmanx layer -127 is used as the X11 desktop.

So with '--layer -128' omxplayer should play the video behind the desktop. Question is how to create a hole in the desktop :D

Another question would be, can a tkinter application run on an other (/higher) layer than the desktop layer?

Return to “Python”