ofOMXPlayer fading FULL HD videos

I’m trying to make a fade in/fade out effect with ofOMXPlayer on a RPi2. So far I can do it by enabling textured mode in the settings of ofOMXPlayer, but if I do so, my full hd videos are struggling to go full FPS.

Full HD is a must have for my app, and I then need to disable textured mode to get full FPS. Doing that, my fade in/out effect is gone.

Is there any way to have both full HD videos and fade in/fade out effect?

Any examples out there?



I had recently success by overclocking the h264 decoder to achieve fluid 1080p playback with ofxOMXPlayer.
I’m using these settings in my config.txt. Be aware that setting “force_turbo=1” may void your warranty.
Though that setting is needed to enable overclocking of the GPU and VPU.
These setting also slightly decreases analog audio quality. HDMI audio is not affected.
This is quite a heavy overclock for the 3D and h264 part of the GPU so be careful with increasing them even more. Standard for both is 250MHz.


E: Also alterting a setting an option for the cpu govenor:

sudo sh -c "echo 1000 >/sys/devices/system/cpu/cpufreq/ondemand/sampling_down_factor"

More info on overclocking here: http://linuxonflash.blogspot.com.au/2015/02/a-look-at-raspberry-pi-2-performance.html

Thanks @Prof_Sparkles, I’ll give a try.

So with this overclocking you can have a fluid playback even in textured mode?



Indeed. I’ve had the same issue for my application for months now and tried a lot of things to improve performance. This so far is the only solution to your problem. OMX Player has no option for fading built-in.

If video is still lagging you might want to increase CPU clock or decrease the v3d or h264 clock in 50mhz steps. The CPU is a bottleneck in this clock range and starts to decrease the performance with higher GPU and VPU clocks.

You might also run this command before adjusting the clocks:

sudo sh -c "echo 1000 >/sys/devices/system/cpu/cpufreq/ondemand/sampling_down_factor"

This increases the down sample factor of the CPU governor. According to this blog the L2 cache is the bottleneck: http://linuxonflash.blogspot.com.au/2015/02/a-look-at-raspberry-pi-2-performance.html

Thanks @Prof_Sparkles
I tried the overclocking and it works better. But I have some low voltages warnings (squared rainbow on right top of the screen) and the RPi2 ends up freezing.

I’ll try with an official RPi power supply.

I’ll let you know since I think I’ll play with the OC values in config.txt


Yea in that case your USB PSU can’t deliver enough ampere. When overclocking always run the Pi with a 2A PSU.

I’m using a 3A one, but this PSU must be not stable enough.

Haven’t tried the official RPi one.

3A sounds very unusual, the specs for USB charging ports don’t allow for more than 2A per port. Is that a Chinese design from ebay or similar sources? They tend to slap made up ratings on them while they actually just deliver around 500ma.

Sometime its also just the cable if you are using a really long one.
No need really for the “official” PSU, a brand phone charger is more than enough.
For the brown out icon to appear the voltage from the PSU would really need to drop quite a bit, which usually only happens if your device is drawing more current than the PSU can deliver, then the output voltage takes a nose dive.

It’s a standard PSU with a µ-USB cable (this one http://www.reichelt.de/Universalnetzteile/MW-3H36GS/3/index.html?ACTION=3&GROUPID=4945&ARTICLE=89789&OFFSET=16&SID=14VWWayKwQATYAAEde@t04a326abf70786f6277c6172688e2b4ff&LANGUAGE=EN)

anyway, after some tests with the “official” RPi PSU, I have no problems, it seems pretty stable.

Thanks @Prof_Sparkles for your valuable help!

Ooh ok, yea those variable PSUs are generally horrible. Ok for lighting and such but if you need a somewhat stable voltage they are pretty crap most of the time.
Just get one of these guys: http://www.amazon.de/AmazonBasics-USB-Netzteil -Ladegerät-1 -Output/dp/B00JWXT6BK/

Or if you have multiple USB powered devices maybe something like this: http://www.amazon.de/Ladegerät-Technologie-Netzkabel-Smartphones-USB-ladende/dp/B00GTGS2I6

Glad I could help.

I typically use the iPhone wall charger and it has been pretty good (though pricy)

Overclocking indeed does fix the glitching/tearing when using ofxOMXPlayer in textured mode with 1080p video.
Thanks a lot for this information!
I’m currently using these settings:


I’m till tweaking to get the last minor glitches out.
v3d_freq or h264_freq at 300 or 350 seems to give better results than 400+, but im wondering which is more important for ofxOMXPlayer. Do they have to be the same?