[FFmpeg-user] Info

2022-09-20 Thread Dan
Hi, 

I'm trying to run a stream on YouTube a video that loops 24/7, using FFmpeg 4.4 
from a server with Ubuntu 22, but cannot succeed, any help would be appreciated.

Here's 2 scripts I made, the 1st one works with a CPU showing around 75% but 
does not loop.

VBR="1500k"
FPS="24"
QUAL="superfast"

YOUTUBE_URL="rtmp://a.rtmp.youtube.com/live2"
KEY="mykey"
SOURCE="/home/ubuntu/Video.mp4"
AUDIO_SOURCE="/home/ubuntu/Music.mp3"
ffmpeg \
-re -f lavfi -i "movie=filename=$SOURCE:loop=0, setpts=N/(FRAME_RATE*TB)" \
-thread_queue_size 512 -i "$AUDIO_SOURCE" \
-map 0:v:0 -map 1:a:0 \
-map_metadata:g 1:g \
-vcodec libx264 -pix_fmt yuv420p -preset $QUAL -r $FPS -g $(($FPS * 2)) 
-b:v $VBR \
-acodec libmp3lame -ar 44100 -threads 6 -qscale:v 3 -b:a 32 -bufsize 
512k \
-f flv "$YOUTUBE_URL/$KEY"


The 2nd script loops but the CPU on the server shows 190% and I loose the 
"Live" red light on YouTube.


VBR="1500k"
FPS="24"  
QUAL="superfast" 

YOUTUBE_URL="rtmp://a.rtmp.youtube.com/live2"  
SOURCE="/home/ubuntu/Video.mp4"  
KEY="mykey"  
ffmpeg \
-stream_loop -1 -i "$SOURCE" -deinterlace \
-vcodec libx264 -pix_fmt yuv420p -preset $QUAL -r $FPS -g $(($FPS * 2)) 
-b:v $VBR \
-acodec libmp3lame -ar 44100 -threads 6 -qscale 3 -b:a 712000 -bufsize 512k 
\
-f flv "$YOUTUBE_URL/$KEY"

Thanks.
Dan



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

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


[FFmpeg-user] ffmpeg problem: Wrong or missing size information for certain EXRs

2022-09-20 Thread Kevin Steele
Hi! I am trying to convert EXRs to a quicktime video. It has worked several
times for me in the past. However, sometimes it doesn't work mysteriously
on certain exrs and I am not clear why.
Below is a google drive link to the exr file as an example; I assume people
may need to reproduce this. The file is too big to include in an email. The
EXR opens fine for me in various programs.
https://drive.google.com/file/d/1p4l5XOSQYOyfV6ojdWP0CZGLFPWmIcJa/view?usp=sharing
I have tested this on both my mac and windows and I get the issue on both
platforms. I am using a new version of ffmpeg from 2022.
The command I tried is below:

ffmpeg -analyzeduration 9223372036854775807 -probesize 9223372036854775807
-s 1280x720 -i Window_v001.1001.exr -codec:v libx264 -s
1280x720  Window_v001.mov


Below are things I have already tried, as you can tell from my
command above:

 - setting analyzeduration and probesize to highest possible values

- forcing the size

- I have also tried various codecs.


This exr was rendered from a program called 3ds Max: I'm not sure if that
matters. However, often fmmpeg works totally fine with exrs rendered from
3ds. It just mysteriously fails sometimes.


Anyone have any ideas/suggestions? Thanks so much
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-user

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


Re: [FFmpeg-user] Size of 10-bit 4:2:2 video streams?

2022-09-20 Thread Carl Zwanzig

Hello,

On 9/20/2022 6:11 AM, Bruchez Olivier via ffmpeg-user wrote:

So I made some further tests and discovered that my original AVI file is
simply corrupted. It's supposed to have 88 minutes of video, but it fails
after 38 minutes. 


What does "fails" mean? The player stops? Which player? The video goes black 
but playing continues? Please be specific.




I didn't notice this for the simple reason that ffmpeg "fails" (?) silently 
after 38 minutes. It doesn't output any error message. It just stops after
38 minutes. Example for an AVI-to-AVI copy:
...
frame=57978 fps=154 q=-1.0 size=62615951kB time=00:38:39.12 
bitrate=221183.0kbits/s speed=6.14x
frame=58011 fps=153 q=-1.0 size=62651535kB time=00:38:40.44 
bitrate=221182.8kbits/s speed=6.14x
frame=58047 fps=153 q=-1.0 size=62690447kB time=00:38:41.88 bitrate=221182.9kbits/s 


a) as long as the status messages continue, it doesn't look like anything 
has stopped.


b) the complete command line is missing, so we don't know what's actually 
being done.


You may want to try multiple players to see what's in the file and look at 
it with ffprobe and mediainfo. Also try encoding into a different format 
which will force ffmpeg to demux/decode the frames; that might turn up 
something.



As per the list FAQ, always include the complete command line and DO NOT 
top-post.


z!
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-user

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


Re: [FFmpeg-user] Size of 10-bit 4:2:2 video streams?

2022-09-20 Thread Bruchez Olivier via ffmpeg-user
Hi all,

So I made some further tests and discovered that my original AVI file is simply 
corrupted. It's supposed to have 88 minutes of video, but it fails after 38 
minutes. That's why all the files I generated were smaller than expected.

I didn't notice this for the simple reason that ffmpeg "fails" (?) silently 
after 38 minutes. It doesn't output any error message. It just stops after 
38 minutes. Example for an AVI-to-AVI copy:

...
frame=57978 fps=154 q=-1.0 size=62615951kB time=00:38:39.12 
bitrate=221183.0kbits/s speed=6.14x
frame=58011 fps=153 q=-1.0 size=62651535kB time=00:38:40.44 
bitrate=221182.8kbits/s speed=6.14x
frame=58047 fps=153 q=-1.0 size=62690447kB time=00:38:41.88 
bitrate=221182.9kbits/s speed=6.13x
frame=58083 fps=153 q=-1.0 size=62729359kB time=00:38:43.32 
bitrate=221183.0kbits/s speed=6.13x
frame=58119 fps=153 q=-1.0 size=62768271kB time=00:38:44.76 
bitrate=221183.1kbits/s speed=6.12x
frame=58133 fps=153 q=-1.0 size=62783375kB time=00:38:45.32 
bitrate=221183.1kbits/s speed=6.12x
frame=58172 fps=153 q=-1.0 size=62825359kB time=00:38:46.88 
bitrate=221182.6kbits/s speed=6.11x
frame=58211 fps=153 q=-1.0 size=62867599kB time=00:38:48.44 
bitrate=221183.0kbits/s speed= 6.1x
frame=58254 fps=152 q=-1.0 Lsize=62915254kB time=00:38:50.12 
bitrate=221191.1kbits/s speed=6.08x
video:62914320kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB 
muxing overhead: 0.001485%

I guess I will have to check the file on our LTO tapes...

Does anybody have any suggestion about how I could retrieve the video stream 
after 38 minutes? Knowing that it's supposed to be "uncompressed" video (i.e. 
v210 / yuv422p10l)?

Thanks in advance,
Olivier

On 9/15/22, Bruchez Olivier via ffmpeg-user  wrote:
> Hi all,
>
> I have a 10-bit 4:2:2 (yuv422p10le) AVI file containing only a video
> stream:
>
> Input #0, avi, from 'test.avi':
>   Duration: 01:28:00.80, start: 0.00, bitrate: 221185 kb/s
>   Stream #0:0: Video: v210 (v210 / 0x30313276), yuv422p10le, 720x576, 25
> fps, 25 tbr, 25 tbn, 25 tbc
>
> The file has a size of 146 GB = 146004770816 bytes.
>
> Am I correct to infer that those 10-bit YUV values are grouped into 30-bit
> packets and encoded into 32-bit/4-byte packets?
>
> With 20 bits per pixel (Y + either U or V), that would give a theoretical
> file size of:
>
> 88 * 60 * 25 * 720 * 576 * (10 + 10) / 30 * 32 / 8 = 14598144 bytes
>
> Which seems to more or less match the original file size.
>
> Now here's my problem. When I extract the raw video stream:
>
> ffmpeg -i test.avi -c:v rawvideo -pix_fmt yuv422p10le -f rawvideo test.raw
>
> I get a RAW video file with a size of 96 GB = 96636395520 bytes. I’ve lost
> one third of the video stream.
>
> Another strange thing: if I copy the video stream to another AVI file:
>
> ffmpeg -i test.avi -c copy test.copy.avi
>
> The resulting file has a size of 64 GB = 64425220302 bytes. This time I’ve
> lost 56% of the video stream.
>
> What's happening here? It seems like I’m missing something obvious.
>
> Thanks for any help,
> Olivier


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

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


[FFmpeg-user] how to remove sawtooth effect caused by rotate and overaly filters

2022-09-20 Thread qw
Hi,


I use the following ffmpeg command to do some rotation effect on video stream:


ffmpeg -y -i video.mp4 -t 25 -vcodec libx264 -r 25 -preset medium 
-filter_complex 
"color=size=720x406:c=black[bg];[0:v]setpts=PTS-STARTPTS,format=yuva420p,rotate=25*PI/180:c=0x:ow=rotw(25*PI/180):oh=roth(25*PI/180)[timeline_t0_c0];[bg][timeline_t0_c0]overlay=96:32:eof_action=pass[outv]"
 -filter_complex 
"[0:a]adelay=delays=0:all=1[timeline_t0_c0_a];[timeline_t0_c0_a]amix=1[outa]" 
-map "[outv]" -map "[outa]" -f mp4 rotation.out.mp4


sawtooth effect is noticeable at the overlay boundary between background and 
video images. I use one online video editor to do the same thing, i.e. 
https://www.online-image-editor.com/. There is no noticeable sawtooth effect. 
The video editor should do some special operation on the boundary.


how to remove sawtooth effect caused by rotate and overaly filters?


Thanks!


Regards


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

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