evanthemann7
Posts: 10
Joined: Wed Jun 13, 2018 3:57 pm

Original Raspberry Pi B, video playback choppy on Pi_Video_Looper software from Adafruit

Thu Jan 17, 2019 3:53 pm

Installed NOOBS on an 8GB SD card and installed Raspbian. Then, installed Adafruit's Pi Video Looper. Inserting a USB stick with a video, the 1280x720p video played back choppy, not fluid. I severely reduced the quality and filesize of the video, but now I just have a low quality video still playing choppy. It plays at a lower framerate than original video. Any ideas why this could be? Can the original pi handle video playback? Thanks. I am playing through RCA video, not HDMI.

https://learn.adafruit.com/raspberry-pi ... r/overview

tvjon
Posts: 675
Joined: Mon Jan 07, 2013 9:11 am

Re: Original Raspberry Pi B, video playback choppy on Pi_Video_Looper software from Adafruit

Thu Jan 17, 2019 4:24 pm

Original is perfectly capable. Until recently, it was all I used for Kodi.


Try playing

/opt/vc/src/hello_pi/hello_video/test.h264

to see if that's choppy.

If so, in that same folder is a

Makefile

for hello_video.bin

Type

make

in a terminal window to build the application, then

$ ./hello_video.bin test.h264

& compare the video quality with the looper.

User avatar
rpiMike
Posts: 706
Joined: Fri Aug 10, 2012 12:38 pm
Location: Cumbria, UK

Re: Original Raspberry Pi B, video playback choppy on Pi_Video_Looper software from Adafruit

Thu Jan 17, 2019 4:30 pm

Whats your GPU memory set to ?

evanthemann7
Posts: 10
Joined: Wed Jun 13, 2018 3:57 pm

Re: Original Raspberry Pi B, video playback choppy on Pi_Video_Looper software from Adafruit

Thu Jan 17, 2019 6:45 pm

rpiMike wrote:
Thu Jan 17, 2019 4:30 pm
Whats your GPU memory set to ?
Thanks for the reply. I'm not sure how to check that.

evanthemann7
Posts: 10
Joined: Wed Jun 13, 2018 3:57 pm

Re: Original Raspberry Pi B, video playback choppy on Pi_Video_Looper software from Adafruit

Thu Jan 17, 2019 6:47 pm

tvjon wrote:
Thu Jan 17, 2019 4:24 pm
Original is perfectly capable. Until recently, it was all I used for Kodi.


Try playing

/opt/vc/src/hello_pi/hello_video/test.h264

to see if that's choppy.

If so, in that same folder is a

Makefile

for hello_video.bin

Type

make

in a terminal window to build the application, then

$ ./hello_video.bin test.h264

& compare the video quality with the looper.
Ok. I'm not sure if you're familiar with this looper but it opens on boot. I think I can get out of it though. I'll get back to Raspbian deskotp and try playing that file to see if it's choppy on my monitor. The monitor is an old Coby portable TV.
Thanks

User avatar
rpiMike
Posts: 706
Joined: Fri Aug 10, 2012 12:38 pm
Location: Cumbria, UK

Re: Original Raspberry Pi B, video playback choppy on Pi_Video_Looper software from Adafruit

Thu Jan 17, 2019 8:19 pm

evanthemann7 wrote:
Thu Jan 17, 2019 6:45 pm
rpiMike wrote:
Thu Jan 17, 2019 4:30 pm
Whats your GPU memory set to ?
Thanks for the reply. I'm not sure how to check that.
Assuming your using Raspbian Stretch with Desktop, select applications menu, then 'Preferences', 'Raspberry Pi Configuration', 'Performance' tab

evanthemann7
Posts: 10
Joined: Wed Jun 13, 2018 3:57 pm

Re: Original Raspberry Pi B, video playback choppy on Pi_Video_Looper software from Adafruit

Fri Jan 18, 2019 2:12 am

@tvjon

Tried playing that video file. VLC player opened and closed a bunch of times but finally it did play it. But when playing it was a little choppy. From the cmd line I used omxplayer with the following code and it played smoothly. That's the kind of performance I'm looking for.

Code: Select all

omxplayer /opt/vc/src/hello_pi/hello_video/test.h264


User avatar
rpiMike
Posts: 706
Joined: Fri Aug 10, 2012 12:38 pm
Location: Cumbria, UK

Re: Original Raspberry Pi B, video playback choppy on Pi_Video_Looper software from Adafruit

Fri Jan 18, 2019 7:36 am

Try increasing it to 128

tvjon
Posts: 675
Joined: Mon Jan 07, 2013 9:11 am

Re: Original Raspberry Pi B, video playback choppy on Pi_Video_Looper software from Adafruit

Fri Jan 18, 2019 8:43 am

evanthemann7 wrote:
Fri Jan 18, 2019 2:12 am
@tvjon

... VLC player opened and closed a bunch of times but finally it did play it. But when playing it was a little choppy. From the cmd line I used omxplayer with the following code and it played smoothly. That's the kind of performance I'm looking for...


VLC has a great deal of code which is probably irrelevant for what you need, & is not optimised for a RPi1.

omxplayer is designed specifically for RPi, & in general does an excellent job. I use it for AV daily.

However, it too is overkill if you just need to play .h264 files that aren't in a container, so have no audio.

If you need audio, then omxplayer can be made to loop & there's a post I made in the graphics, multimedia sub forum some time ago that describes how I did it. That works for me. Without knowing what kind of files you're wishing to loop, it may or may not work for your application.

$ sudo apt install mediainfo

will give you a program which will tell you lots of information about your video files.

evanthemann7
Posts: 10
Joined: Wed Jun 13, 2018 3:57 pm

Re: Original Raspberry Pi B, video playback choppy on Pi_Video_Looper software from Adafruit

Mon Jan 21, 2019 3:31 pm

rpiMike wrote:
Fri Jan 18, 2019 7:36 am
Try increasing it to 128
Increased GPU to 128, playback is still choppy.

evanthemann7
Posts: 10
Joined: Wed Jun 13, 2018 3:57 pm

Re: Original Raspberry Pi B, video playback choppy on Pi_Video_Looper software from Adafruit

Mon Jan 21, 2019 3:32 pm

tvjon wrote:
Fri Jan 18, 2019 8:43 am
evanthemann7 wrote:
Fri Jan 18, 2019 2:12 am
@tvjon

... VLC player opened and closed a bunch of times but finally it did play it. But when playing it was a little choppy. From the cmd line I used omxplayer with the following code and it played smoothly. That's the kind of performance I'm looking for...


VLC has a great deal of code which is probably irrelevant for what you need, & is not optimised for a RPi1.

omxplayer is designed specifically for RPi, & in general does an excellent job. I use it for AV daily.

However, it too is overkill if you just need to play .h264 files that aren't in a container, so have no audio.

If you need audio, then omxplayer can be made to loop & there's a post I made in the graphics, multimedia sub forum some time ago that describes how I did it. That works for me. Without knowing what kind of files you're wishing to loop, it may or may not work for your application.

$ sudo apt install mediainfo

will give you a program which will tell you lots of information about your video files.
I'd ideally like to use files created on ios, so .MOV files. However, I can convert them to standard h264 files too. No audio needed.

tvjon
Posts: 675
Joined: Mon Jan 07, 2013 9:11 am

Re: Original Raspberry Pi B, video playback choppy on Pi_Video_Looper software from Adafruit

Tue Jan 22, 2019 4:05 pm

evanthemann7 wrote:
Mon Jan 21, 2019 3:32 pm
...'d ideally like to use files created on ios, so .MOV files. However, I can convert them to standard h264 files too. No audio needed.
Yes, iOS is nice for producing high quality videos.

MP4Box in the gpac suite is a useful tool to extract the h264 stream from mux'd files. It runs fine on RPi.

hello_video.bin

would then be good for looping. There's a small modification to its source code to make it loop within the program, or you can simply write a short shell script to tell it to loop.

evanthemann7
Posts: 10
Joined: Wed Jun 13, 2018 3:57 pm

Re: Original Raspberry Pi B, video playback choppy on Pi_Video_Looper software from Adafruit

Tue Jan 22, 2019 9:04 pm

tvjon wrote:
Tue Jan 22, 2019 4:05 pm

Yes, iOS is nice for producing high quality videos.

MP4Box in the gpac suite is a useful tool to extract the h264 stream from mux'd files. It runs fine on RPi.

hello_video.bin

would then be good for looping. There's a small modification to its source code to make it loop within the program, or you can simply write a short shell script to tell it to loop.
Sorry, I am not familiar with MP4Box, gpac, or what "mux'd" files mean. I am a novice with the Pi still. Just trying to make this choppy video play smoothly after installing the pi video looper. What is hello_video.bin? I also would like to learn shell scripting but right now am not familiar with it.

tvjon
Posts: 675
Joined: Mon Jan 07, 2013 9:11 am

Re: Original Raspberry Pi B, video playback choppy on Pi_Video_Looper software from Adafruit

Wed Jan 23, 2019 12:13 pm

evanthemann7 wrote:
Tue Jan 22, 2019 9:04 pm
...
Sorry, I am not familiar with MP4Box, gpac, or what "mux'd" files mean. I am a novice with the Pi still. Just trying to make this choppy video play smoothly after installing the pi video looper. What is hello_video.bin? I also would like to learn shell scripting but right now am not familiar with it.

Ah, your statement:

"However, I can convert them to standard h264 files too"

led me to believe you might be familiar with demultiplexing a video file into its constituent video (& if required) audio stream. If you're interested in more details there are lots of good reference web sites you can find.


Well, you've already achieved smooth playback using omxplayer, so now you just need to run it in a loop.

Please read ALL of my original reply to your post.


That's good. Education is after all, Raspberry Pi's raison d'être.

If you're happy with hello_video.bin performance too you just need to decide which of the 2 programs you'd like to make loop.

If I get time later today, I'll try to find my original post with loop instructions.

evanthemann7
Posts: 10
Joined: Wed Jun 13, 2018 3:57 pm

Re: Original Raspberry Pi B, video playback choppy on Pi_Video_Looper software from Adafruit

Mon Feb 04, 2019 7:25 pm

Update: The program runs video smoothly when using HDMI.

Recap:
Using Adafruit Pi Video Looper software, original Pi B playback choppy video through composite video output. Plays smoothly through HDMI. Tested playing a videofile via composite with omxplayer, it played smoothly.

Can anyone help or point me in a direction of writing a program using omxplayer so i can plug in a usb stick and it will loop the video file on it?

Thanks

Return to “Troubleshooting”