Re: [FFmpeg-user] Video and Audio is off-sync on Decklink SDI output

2017-02-22 Thread Carl Eugen Hoyos
2017-02-22 23:32 GMT+01:00 Tung Tran :

> * ffmpeg -i rtmp://something  -vf "setpts=PTS-STARTPTS" -af
> "asetpts=PTS-STARTPTS" -f decklink -pix_fmt uyvy422  "DeckLink SDI" *

Complete, uncut console output missing.
Why are you using filters?

> Video and audio of input rtmp is synced on VLC or other software.

Does the following produce a file that plays in-sync?
$ ffmpeg -i rtmp://something -qscale 2 out.avi

Carl Eugen
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-user] Video and Audio is off-sync on Decklink SDI output

2017-02-22 Thread Tung Tran
Dear all

I am testing to setup a decoder with ffmpeg, take live stream in
(RTMP/HLS,.) and output to Decklink SDI.
Its working but I have the issue of audio and video is off-sync on decklink
SDI output, I tried to play around with vf setpts and af asetpts but
couldnt make video/audio to sync.

Any input will be very appreciated.
Here is my command so far

* ffmpeg -i rtmp://something  -vf "setpts=PTS-STARTPTS" -af
"asetpts=PTS-STARTPTS" -f decklink -pix_fmt uyvy422  "DeckLink SDI" *

Video and audio of input rtmp is synced on VLC or other software.
---
Best regards,

*Tung Tran*
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] decode a video with nvdec (nvidia video sdk 7.1) and ffmpeg

2017-02-22 Thread Lou
On Wed, 22 Feb 2017 08:28:06 -0800 (PST)
gofrane  wrote:

> How can I enable and use nvdec(nvidia video sdk 7.1) with ffmpeg to decode a
> video??

Some examples here:
http://trac.ffmpeg.org/wiki/HWAccelIntro#CUDACUVIDNvDecode
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-user] decode a video with nvdec (nvidia video sdk 7.1) and ffmpeg

2017-02-22 Thread gofrane


How can I enable and use nvdec(nvidia video sdk 7.1) with ffmpeg to decode a
video??

thank you




--
View this message in context: 
http://www.ffmpeg-archive.org/decode-a-video-with-nvdec-nvidia-video-sdk-7-1-and-ffmpeg-tp4679258.html
Sent from the FFmpeg-users mailing list archive at Nabble.com.
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] cropping problem

2017-02-22 Thread Carles Vila
El 22 feb. 2017 16:46, "Benjamin Houtman"  escribió:

Hello all,


I'm trying to crop a video that has a large green stripe at the bottom.
Using Cropdetect I've determined that the dimensions of the content for the
video are 720:480, not the 720:576 it displays at. When I try to crop it
two things happen (or don't happen, rather): A) It doesn't produce a file I
can play in quicktime, which my company would like to do, and B) when I
play it using ffplay, it did not crop the video.


The code I used (with variations) is below:


ffmpeg -i /Volumes/VIDEO_1/2009-10-28-Cmp-Multi-1872-C1.mov -vf
"crop=720:480:0:0" -c:v libx264 -crf 15 -c:a copy
/Users/tbdcpreservation/Desktop/FFMpeg_output/crop.mov


There are two things that appear during the process that I haven't been
able to determine how to fix yet:


[mov,mp4,m4a,3gp,3g2,mj2 @ 0x7fd9ea807000] Using non-standard frame rate
62500/100

Guessed Channel Layout for Input Stream #0.1 : stereo



No pixel format specified, yuv422p for H.264 encoding chosen.

Use -pix_fmt yuv420p for compatibility with outdated media players.


The frame rate for the original video is 25/sec, as I'm sure you've noted.
It's German. I've run the file through mediainfo -f and haven't seen
anything about pixel format, so I'm not sure what to do with that.


Any pointers on how to get a workable file?


Best,

Ben Houtman
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


use -vf format=yuv420p or -pix_fmt yuv420p
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] Ffmpeg doesn't recognize /dev/video0 when run as root?

2017-02-22 Thread Reindl Harald



Am 22.02.2017 um 18:17 schrieb christina zou:

Thanks for the tip.

To be honest, I'm hacking on a personal project for fun, security isn't
really a concern.


i better don't comment that attitude which leads to trained misbehavior 
in general



Raspberry Pi (which I'm using) recommends placing startup scripts in
rc.local in its official documentation:
https://www.raspberrypi.org/documentation/linux/usage/rc-local.md


However, if /dev/video0 can't be recognized as root, I'll follow your
advice and run my Ffmpeg command elsewhere.


i said "man su"
su -c "command" - user


On Wed, Feb 22, 2017 at 9:09 AM, Reindl Harald 
wrote:




Am 22.02.2017 um 18:07 schrieb christina zou:


better question - why would anybody start anything dangerous like



multimedia encoders as root? maybe something like SELinux/appamor is
protecting your from yourself

You are probably right.

I want a Ffmpeg command to automatically start when I boot my Pi, without
any interfacing required (login/authentication). I've currently stuck the
command in /etc/rc.local, where everything runs as root. Do you know where
to better place it?



surely, a proper service which drops to a restricted user

with systemd a few lines, for sysvinit there are thousands of explaes how
to start a service proper, and if you don't get something better just "man
su"

on proper systems rc.local died in 2011


___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] Ffmpeg doesn't recognize /dev/video0 when run as root?

2017-02-22 Thread christina zou
Thanks for the tip.

To be honest, I'm hacking on a personal project for fun, security isn't
really a concern.

Raspberry Pi (which I'm using) recommends placing startup scripts in
rc.local in its official documentation:
https://www.raspberrypi.org/documentation/linux/usage/rc-local.md


However, if /dev/video0 can't be recognized as root, I'll follow your
advice and run my Ffmpeg command elsewhere.

On Wed, Feb 22, 2017 at 9:09 AM, Reindl Harald 
wrote:

>
>
> Am 22.02.2017 um 18:07 schrieb christina zou:
>
>> better question - why would anybody start anything dangerous like
>>>
>> multimedia encoders as root? maybe something like SELinux/appamor is
>> protecting your from yourself
>>
>> You are probably right.
>>
>> I want a Ffmpeg command to automatically start when I boot my Pi, without
>> any interfacing required (login/authentication). I've currently stuck the
>> command in /etc/rc.local, where everything runs as root. Do you know where
>> to better place it?
>>
>
> surely, a proper service which drops to a restricted user
>
> with systemd a few lines, for sysvinit there are thousands of explaes how
> to start a service proper, and if you don't get something better just "man
> su"
>
> on proper systems rc.local died in 2011
>
> ___
> ffmpeg-user mailing list
> ffmpeg-user@ffmpeg.org
> http://ffmpeg.org/mailman/listinfo/ffmpeg-user
>
> To unsubscribe, visit link above, or email
> ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
>
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] Ffmpeg doesn't recognize /dev/video0 when run as root?

2017-02-22 Thread Reindl Harald



Am 22.02.2017 um 18:07 schrieb christina zou:

better question - why would anybody start anything dangerous like

multimedia encoders as root? maybe something like SELinux/appamor is
protecting your from yourself

You are probably right.

I want a Ffmpeg command to automatically start when I boot my Pi, without
any interfacing required (login/authentication). I've currently stuck the
command in /etc/rc.local, where everything runs as root. Do you know where
to better place it?


surely, a proper service which drops to a restricted user

with systemd a few lines, for sysvinit there are thousands of explaes 
how to start a service proper, and if you don't get something better 
just "man su"


on proper systems rc.local died in 2011
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] Ffmpeg doesn't recognize /dev/video0 when run as root?

2017-02-22 Thread christina zou
> better question - why would anybody start anything dangerous like
multimedia encoders as root? maybe something like SELinux/appamor is
protecting your from yourself

You are probably right.

I want a Ffmpeg command to automatically start when I boot my Pi, without
any interfacing required (login/authentication). I've currently stuck the
command in /etc/rc.local, where everything runs as root. Do you know where
to better place it?
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] Ffmpeg doesn't recognize /dev/video0 when run as root?

2017-02-22 Thread Reindl Harald



Am 22.02.2017 um 18:01 schrieb christina zou:

If I run my FFMPEG command as root, it does not recognize /dev/video0
properly:

16:17:22 E: Opening an input file: /dev/video0.

16:17:22 E: [video4linux2,v4l2 @ 0x2dff610] fd:4 capabilities:101

16:17:22 E: [video4linux2,v4l2 @ 0x2dff610] The device does not support the
streaming I/O method.

16:17:22 E: /dev/video0: Function not implemented

If I run as user, the FFMPEG command recognizes /dev/video0 and works
properly, no errors. Why?


better question - why would anybody start anything dangerous like 
multimedia encoders as root? maybe something like SELinux/appamor is 
protecting your from yourself

___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-user] Ffmpeg doesn't recognize /dev/video0 when run as root?

2017-02-22 Thread christina zou
If I run my FFMPEG command as root, it does not recognize /dev/video0
properly:

16:17:22 E: Opening an input file: /dev/video0.

16:17:22 E: [video4linux2,v4l2 @ 0x2dff610] fd:4 capabilities:101

16:17:22 E: [video4linux2,v4l2 @ 0x2dff610] The device does not support the
streaming I/O method.

16:17:22 E: /dev/video0: Function not implemented

If I run as user, the FFMPEG command recognizes /dev/video0 and works
properly, no errors. Why?

Full command:

ffmpeg -loglevel debug \

-thread_queue_size 1024 \

-s 640x480 -c:v h264 -f v4l2 -framerate 10 -i /dev/video0 \

-thread_queue_size 1024 \

-i /tmp/temp.mp3 \

-c:a copy \

-c:v copy \

-b:v 300K \

-max_interleave_delta 200 \

-report \

-f flv rtmp://209.85.230.23/live2/KEY
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-user] cropping problem

2017-02-22 Thread Benjamin Houtman
Hello all,


I'm trying to crop a video that has a large green stripe at the bottom.
Using Cropdetect I've determined that the dimensions of the content for the
video are 720:480, not the 720:576 it displays at. When I try to crop it
two things happen (or don't happen, rather): A) It doesn't produce a file I
can play in quicktime, which my company would like to do, and B) when I
play it using ffplay, it did not crop the video.


The code I used (with variations) is below:


ffmpeg -i /Volumes/VIDEO_1/2009-10-28-Cmp-Multi-1872-C1.mov -vf
"crop=720:480:0:0" -c:v libx264 -crf 15 -c:a copy
/Users/tbdcpreservation/Desktop/FFMpeg_output/crop.mov


There are two things that appear during the process that I haven't been
able to determine how to fix yet:


[mov,mp4,m4a,3gp,3g2,mj2 @ 0x7fd9ea807000] Using non-standard frame rate
62500/100

Guessed Channel Layout for Input Stream #0.1 : stereo



No pixel format specified, yuv422p for H.264 encoding chosen.

Use -pix_fmt yuv420p for compatibility with outdated media players.


The frame rate for the original video is 25/sec, as I'm sure you've noted.
It's German. I've run the file through mediainfo -f and haven't seen
anything about pixel format, so I'm not sure what to do with that.


Any pointers on how to get a workable file?


Best,

Ben Houtman
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-user] Udp recording

2017-02-22 Thread יוסף אלון
Hii

I am trying to develop an ffmpeg udp recording in c.
Do you know any example to help me with this?

I sew a few example and trued ti understand with no success..

-- 
בברכה, יוסף אלון
050-4916740
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] How do bitrate, FPS, and speed interact?

2017-02-22 Thread christina zou
Maybe a more basic question:

If Ffmpeg reports 8Mbps bitrate, 0.1x speed, 2FPS, does that mean it's
actually sending 8Mbps or 800Kbps?
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] -c:v or -vcodec copy or -codec:v

2017-02-22 Thread Cley Faye
2017-02-22 8:39 GMT+01:00 Tim Hiles :

> What is the deal with all the different ways to copy?  Do they all do the
> same thing? Cause if not, it is NOT clear what they are and if soseems
> like a lot of redundancy.
>

I
​'m not​ sure from what they come from, but they achieve the same thing.
From the documentation:

​-vcodec codec (output)
> Set the video codec. This is an alias for -codec:v.​


​-c is just a shortcut for -codec, and :v is used to apply the argument to
video streams.​
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] -c:v or -vcodec copy or -codec:v

2017-02-22 Thread Moritz Barsnick
On Wed, Feb 22, 2017 at 04:58:12 -0800, DopeLabs wrote:
> c:v is an abbreviated version of codec:v
> vcodec is an alias of codec:v
> 
> So all 3 function the same, but are not limited to 'copy' only. It is used to 
> specify the codec, or copy.

(I don't find this confusing either. And the docs/wiki seem to
concentrate primarily on the "-c:X" variant.)

To add to the absolutely perfect answer:

You can also set a "default" method with an initial "-c", and more
specific ones afterwards:

$ ffmpeg [...] -c copy -c:s srt [...]
will use "copy" for all stream types, except for subtitles.

$ ffmpeg [...] -c:a copy -c:a:3 mp2 [...]
will use "copy" for all audio streams except for the third (fourth!) audio
stream.

Moritz
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] How do bitrate, FPS, and speed interact?

2017-02-22 Thread Moritz Barsnick
On Tue, Feb 21, 2017 at 19:03:09 -0800, christina zou wrote:
> If I bump the bitrate to 1Mbps in both raspivid and FFMPEG, then FFMPEG's
> stderr tells me that it hits 1Mbps, but the speed is reported around 0.67x
> and my FPS is ~10, 2/3 of my target FPS.

That probably means that encoding to 1 Mb/s, i.e. at a higher quality,
takes more CPU resources.

> My CPU usage doesn't go above 25%, and my wifi is capable of at max 5Mbps
> upload speed, far higher than the 1Mbps video bitrate I'm attempting.

Are you sure that is the net WiFi rate you can achieve?

Are you sure that your CPU is not a four-core, and is actually at 100 %
on the one core ffmpeg is using for its main task? (You might be able
to see each core's load/CPU usage with a different view in "top", or
with "htop".)

> I'm trying to understand what is happening when Ffmpeg manages to hit my
> specified higher video bitrates, but at the sacrifice of FPS and speed. Is
> this because my internet is too slow?
> 
> My command: http://vpaste.net/kl3Vi

a) You should have pasted that here. (It's short enough!)
b) You should have added the console output of ffmpeg.

I wonder why your setting of the bitrate changes anything at all:
[...]
> -c:v copy \
> -c:a copy \
> -b:v 1000K \
[...]

How do expect to change the (codec's encoding) bitrate if you use
"copy"? No re-encoding takes place in that case.

Moritz
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] -c:v or -vcodec copy or -codec:v

2017-02-22 Thread DopeLabs
c:v is an abbreviated version of codec:v

vcodec is an alias of codec:v

So all 3 function the same, but are not limited to 'copy' only. It is used to 
specify the codec, or copy.

For example

ffmpeg -i INPUT -map 0 -c:v libx264 -c:a copy OUTPUT

encodes all video streams with libx264 and copies all audio streams.

This could also be written as

ffmpeg -i INPUT -map 0 -codec:v libx264 -acodec copy OUTPUT

or

ffmpeg -i INPUT -map 0 -vcodec libx264 -codec:a copy OUTPUT




From the man pages:

-vcodec codec (output)

Set the video codec. This is an alias for "-codec:v".


-c[:stream_specifier] codec (input/output,per-stream)
-codec[:stream_specifier] codec (input/output,per-stream)

Select an encoder (when used before an output file) or a decoder (when used 
before an input file) for one or more streams. codec is the name of a 
decoder/encoder or a special value "copy" (output only to indicate that the 
stream is not to be re-encoded.


For example

ffmpeg -i INPUT -map 0 -c:v libx264 -c:a copy OUTPUT

encodes all video streams with libx264 and copies all audio streams.






> On Feb 21, 2017, at 11:39 51PM, Tim Hiles  wrote:
> 
> Hi all,
> 
> What is the deal with all the different ways to copy?  Do they all do the
> same thing? Cause if not, it is NOT clear what they are and if soseems
> like a lot of redundancy.
> 
> Thanks!
> ___
> ffmpeg-user mailing list
> ffmpeg-user@ffmpeg.org
> http://ffmpeg.org/mailman/listinfo/ffmpeg-user
> 
> To unsubscribe, visit link above, or email
> ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".