18:44
I am encoding a few videos with av1an and svt-av1-psy.
I have one file with audio that goes out of sync. I usually encode the audio in opus, but even remuxing the original stream result in out of sync.
It seems the new av1 video is shorter of 831ms compare to original. Using mkvtoolnix to set -831ms and use the "correct video timing..." option result in a file that is not far of being well sync, but no quiet perfect and the total lenght of the video is even shorter.
So is there any way to use the original h264 video file as a reference for the new AV1 (...)
21:54
I was using video_player to do the rest of the metadata extraction I need but I didn't find a way to get the resolution with this package.
05:05
FFmpeg.AutoGen version: 7.0
Following is similar with Program.cs in "FFmpeg.AutoGen.Example" directory.
var sourceSize = vsd.FrameSize;
var sourcePixelFormat = AVPixelFormat.AV_PIX_FMT_CUDA;
var destinationSize = sourceSize;
var destinationPixelFormat = AVPixelFormat.AV_PIX_FMT_BGRA;
VideoFrameConverter vfc = new VideoFrameConverter(sourceSize, sourcePixelFormat, destinationSize, destinationPixelFormat);
However, when 'ffmpeg.sws_getContext' is called, ffmpeg shows below error message.
ffmpeg error message: [swscaler ⓐ 000001b7af30aa00] (...)
00:47
I need to write function in C that changes sample rate of one audio channel (float linear array).
I have this now:
int resample_audio(float *audio_input, int input_sample_rate, int output_sample_rate, int input_num_of_samples, float *audio_output, int *result_num_of_samples)
SwrContext* swr_ctx = swr_alloc();
if (!swr_ctx)
fprintf(stderr, "Could not allocate SwrContext\\n");
return -1;
av_opt_set_int(swr_ctx, "in_channel_layout", AV_CH_LAYOUT_MONO, 0);
av_opt_set_int(swr_ctx, "out_channel_layout", AV_CH_LAYOUT_MONO, 0);
(...)