Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update ffmpeg.py #31

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

Update ffmpeg.py #31

wants to merge 3 commits into from

Conversation

gcurtis79
Copy link
Contributor

@gcurtis79 gcurtis79 commented Dec 28, 2018

If using "video_input_format=mjpeg" then disable '-video_size'
Otherwise, normal operation.
Should make it a list of incompatible input_formats, but I'm only aware of mjpeg.

Check if using mjpeg as input_format and disable "-video_size" as mjpeg does not use it, and it causes ffmpeg to stop if used.
@gcurtis79
Copy link
Contributor Author

Just a note:

This change will have absolutely no effect on anyone not using mjpeg input format, and requires no additional config options.

With this simple patch to ffmpeg.py, you can now stream from a Pi Zero to LetsRobot.tv with another machine (in my case a Ubuntu Server) with normal config settings.

In my case, I use the following in the standard config file:

[camera]
# Camera stream on my Pi Zero
camera_device = http://192.168.136.199:8080/stream/video.mjpeg

[ffmpeg]
# RSH to remote machine and activate ffmpeg there
ffmpeg_location = rsh <user>@<host> ffmpeg
# The trouble making input format
video_input_format = mjpeg

@gcurtis79
Copy link
Contributor Author

Checking in to see if this should be dropped, or if it's going to be merged. I've been using it for weeks now.

@Nocturnal42
Copy link
Collaborator

It's because there are already several conditionals added to the ffmpeg command line builds, and it makes sense that they should all be handled in a consistent fashion. I've been meaning to go over it and pick a method to go with. I just haven't got around to it.

@gcurtis79
Copy link
Contributor Author

Gotcha. I didn't know if there were any already. I would have made it a list check, but I only knew of the one that caused the error so far.

@Nocturnal42
Copy link
Collaborator

They are mostly in the ffmpeg audio stuff, from memory.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants