Log in

View Full Version : FFmpegSource


Pages : 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 [52] 53 54 55 56 57 58 59 60

l33tmeatwad
1st January 2020, 02:22
Compiled the last official stable release with FFMPEG 4.2.2 libs, figured a few people may be interested in having it so here it is:

FFMS2 2.23.1 (w/ FFmpeg 4.2.2)
Static Libs Build (x86 & x64) (http://www.mediafire.com/file/yyabrt1jkmmlvsn) | Sources (https://www.mediafire.com/folder/3tv37w2c9ibps/Source)

Build Notes:
Compiled with Microsoft Visual Studio 2015
Shared Libs & Include Files were copied to the Visual Studio Directories in: C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC
Patch included with previous releases was applied to FFmpeg before compiling.

Static FFmpeg libs compiled with:
./configure --toolchain=msvc --enable-gpl --enable-version3 --disable-encoders --disable-programs --disable-filters \
--disable-network --disable-doc --disable-avdevice --disable-swresample --disable-postproc --disable-avfilter --enable-avresample
make install

Visual Studio Project Modifications
Project Properties > Configuration Properties > Linker > Input
- Additional Dependencies: bcrypt.lib;

Changes to libs.cpp
#pragma comment(lib, "zlibstat.lib")

Included Libs:
LibAV (from FFmpeg 4.2.2) (https://github.com/ffmpeg/ffmpeg/releases)
zlib 1.2.11 (http://zlib.net)

Other Software:
MSYS2 (https://www.msys2.org/) (i686 & x86_64)
Yasm 1.3.0 (http://yasm.tortall.net/Download.html) (General Use Executables)

FranceBB
1st January 2020, 12:43
Thank you, I just tried the x86 build and it works fine. :)

kedautinh12
3rd January 2020, 09:20
Compiled the last official stable release with FFMPEG 4.2.2 libs, figured a few people may be interested in having it so here it is:

FFMS2 2.23.1 (w/ FFmpeg 4.2.2)
Static Libs Build (x86 & x64) (http://www.mediafire.com/file/yyabrt1jkmmlvsn) | Sources (https://www.mediafire.com/folder/3tv37w2c9ibps/Source)

Build Notes:
Compiled with Microsoft Visual Studio 2015
Shared Libs & Include Files were copied to the Visual Studio Directories in: C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC
Patch included with previous releases was applied to FFmpeg before compiling.

Static FFmpeg libs compiled with:
./configure --toolchain=msvc --enable-gpl --enable-version3 --disable-encoders --disable-programs --disable-filters \
--disable-network --disable-doc --disable-avdevice --disable-swresample --disable-postproc --disable-avfilter --enable-avresample
make install

Visual Studio Project Modifications
Project Properties > Configuration Properties > Linker > Input
- Additional Dependencies: bcrypt.lib;

Changes to libs.cpp
#pragma comment(lib, "zlibstat.lib")

Included Libs:
LibAV (from FFmpeg 4.2.2) (https://github.com/ffmpeg/ffmpeg/releases)
zlib 1.2.11 (http://zlib.net)

Other Software:
MSYS2 (https://www.msys2.org/) (i686 & x86_64)
Yasm 1.3.0 (http://yasm.tortall.net/Download.html) (General Use Executables)

thanks, but still error with .vob file
-[Information] AutoEncode
--[Information] C:\Users\84945\Downloads\Video for test\VTS_01_1.vob.video-muxed.mkv
---[Information] [1/3/2020 8:09:25 AM] No Target Size (use profile settings)
---[Information] [1/3/2020 8:09:25 AM] Split Size: null
---[Information] [1/3/2020 8:09:25 AM] Eliminating duplicate filenames
----[Information] [1/3/2020 8:09:25 AM] Video output file: C:\Users\84945\Downloads\Video for test\VTS_01_1.vob.video.264
----[Information] [1/3/2020 8:09:25 AM] Muxed output file: C:\Users\84945\Downloads\Video for test\VTS_01_1.vob.video-muxed.mkv
----[Information] [1/3/2020 8:09:25 AM] Encodable audio stream 0: C:\Users\84945\Downloads\Video for test\VTS_01_1.vob_track_1_vietnamese.audio.m4a
-[Information] Log for job1 (audio, VTS_01_1.vob_track_1_vietnamese.avs -> VTS_01_1.vob_track_1_vietnamese.audio.m4a)
--[Information] [1/3/2020 8:09:25 AM] Started handling job
--[Information] [1/3/2020 8:09:25 AM] Preprocessing
--[Information] [1/3/2020 8:09:25 AM] MediaInfo
---[Information] File: C:\Users\84945\Downloads\Video for test\VTS_01_1.vob_track_1_vietnamese.avs
---[Information] AVS input file detected. Getting media information from AviSynth.
---[Information] General
----[Information] Format: AVS
----[Information] FormatString: AviSynth Script
----[Information] FileSize: 196
----[Information] PlayTime: 00:03:57.2050000
---[Information] Audio
----[Information] ID: 0
----[Information] Format: AVS
----[Information] SamplingRate: 48000
----[Information] SamplingRateString: 48000
----[Information] Channels: 2
----[Information] ChannelsString: 2 channels
----[Information] BitRateMode: CBR
----[Information] Delay: 0
----[Information] [1/3/2020 8:09:27 AM] The language information is not available for this track. The default MeGUI language has been selected.
--[Information] [1/3/2020 8:09:28 AM] AviSynth script
---[NoImage] ClearAutoloadDirs()
---[NoImage] AddAutoloadDir("E:\MeGUI-2913-64\tools\avs\plugins")
---[NoImage] Import("C:\Users\84945\Downloads\Video for test\VTS_01_1.vob_track_1_vietnamese.avs")
---[NoImage] # detected channels: 2
---[NoImage] # detected channel positions:
---[NoImage] Normalize()
---[NoImage] return last
--[Information] [1/3/2020 8:09:28 AM] Command line used: -ignorelength -cbr 129000 -if - -of "{0}"
--[Information] [1/3/2020 8:09:28 AM] AviSynth script environment opened
--[Information] [1/3/2020 8:09:29 AM] Script loaded
--[Information] [1/3/2020 8:09:29 AM] Output Decoder
---[Information] [1/3/2020 8:09:29 AM] Channels: 2
---[Information] [1/3/2020 8:09:29 AM] Bits per sample: 16
---[Information] [1/3/2020 8:09:29 AM] Sample rate: 48000
--[Information] [1/3/2020 8:09:29 AM] Job command line: E:\MeGUI-2913-64\tools\eac3to\neroAacEnc.exe -ignorelength -cbr 129000 -if - -of "C:\Users\84945\Downloads\Video for test\VTS_01_1.vob_track_1_vietnamese.audio.m4a"
--[Information] [1/3/2020 8:09:29 AM] Process started
--[Information] [1/3/2020 8:09:29 AM] Standard output stream
--[Information] [1/3/2020 8:09:29 AM] Standard error stream
---[Information] [1/3/2020 8:09:33 AM] *************************************************************
---[Information] [1/3/2020 8:09:33 AM] * *
---[Information] [1/3/2020 8:09:33 AM] * Nero AAC Encoder *
---[Information] [1/3/2020 8:09:33 AM] * Copyright 2009 Nero AG *
---[Information] [1/3/2020 8:09:33 AM] * All Rights Reserved Worldwide *
---[Information] [1/3/2020 8:09:33 AM] * *
---[Information] [1/3/2020 8:09:33 AM] * Package build date: Feb 18 2010 *
---[Information] [1/3/2020 8:09:33 AM] * Package version: 1.5.4.0 *
---[Information] [1/3/2020 8:09:33 AM] * *
---[Information] [1/3/2020 8:09:33 AM] * See -help for a complete list of available parameters. *
---[Information] [1/3/2020 8:09:33 AM] * *
---[Information] [1/3/2020 8:09:33 AM] *************************************************************
--[Information] [1/3/2020 8:09:35 AM] MediaInfo
---[Information] File: C:\Users\84945\Downloads\Video for test\VTS_01_1.vob_track_1_vietnamese.audio.m4a
---[Information] General
----[Information] Format: MPEG-4
----[Information] FileSize: 3874803
----[Information] PlayTime: 00:03:57.269
---[Information] Audio
----[Information] ID: 1
----[Information] StreamOrder: 0
----[Information] CodecID: mp4a-40-2
----[Information] Format: AAC
----[Information] FormatInfo: Advanced Audio Codec
----[Information] FormatProfile: LC
----[Information] FormatSettingsSBR: No (Explicit)
----[Information] SamplingRate: 48000
----[Information] SamplingRateString: 48.0 kHz
----[Information] Channels: 2
----[Information] ChannelsString: 2 channels
----[Information] ChannelPositionsString2: 2/0/0
----[Information] BitRateMode: VBR
----[Information] [1/3/2020 8:09:35 AM] The language information is not available for this track. The default MeGUI language has been selected.
--[Information] [1/3/2020 8:09:35 AM] Postprocessing
---[Information] [1/3/2020 8:09:35 AM] Deleting intermediate files
--[Information] [1/3/2020 8:09:35 AM] Job completed
-[Error] Log for job2 (video, VTS_01_1.vob.avs -> VTS_01_1.vob.video.264)
--[Information] [1/3/2020 8:09:35 AM] Started handling job
--[Information] [1/3/2020 8:09:35 AM] Preprocessing
--[Information] [1/3/2020 8:09:35 AM] AviSynth input script
---[NoImage] LoadPlugin("E:\MeGUI-2913-64\tools\ffms\ffms2.dll")
---[NoImage] FFVideoSource("C:\Users\84945\Downloads\Video for test\VTS_01_1.VOB", fpsnum=24000, fpsden=1001, threads=1, colorspace="YUV420P8")
---[NoImage] #deinterlace
---[NoImage] #crop
---[NoImage] LanczosResize(720,392) # Lanczos (Sharp)
---[NoImage] #denoise
--[Information] [1/3/2020 8:09:36 AM] resolution: 720x392
--[Information] [1/3/2020 8:09:36 AM] frame rate: 24000/1001
--[Information] [1/3/2020 8:09:36 AM] frames: 5687
--[Information] [1/3/2020 8:09:36 AM] length: 00:03:57.195
--[Information] [1/3/2020 8:09:36 AM] aspect ratio (avs): 90:49 (1.837)
--[Information] [1/3/2020 8:09:36 AM] color space: I420
--[Warning] [1/3/2020 8:09:36 AM] --vbv-bufsize is not restricted. Maximum value for level 4.1 is 78125. Playback may be affected. Reselect AVC level/profile or target playback device in the x264 preset to set the proper value.
--[Warning] [1/3/2020 8:09:36 AM] --vbv-maxrate is not restricted. Maximum value for level 4.1 is 62500. Playback may be affected. Reselect AVC level/profile or target playback device in the x264 preset to set the proper value.
--[Information] [1/3/2020 8:09:37 AM] Job command line: "E:\MeGUI-2913-64\tools\x264\x264.exe" --level 4.1 --preset veryslow --crf 18 --deblock -3:-3 --keyint 23 --min-keyint 1 --bframes 16 --aq-mode 3 --merange 64 --psy-rd 1.0:0.15 --no-fast-pskip --sar 1:1 --frames 5687 --output "C:\Users\84945\Downloads\Video for test\VTS_01_1.vob.video.264" "C:\Users\84945\Downloads\Video for test\VTS_01_1.vob.avs"
--[Information] [1/3/2020 8:09:37 AM] Process started
--[Information] [1/3/2020 8:09:37 AM] Standard output stream
--[Error] [1/3/2020 8:09:37 AM] Standard error stream
---[Information] [1/3/2020 8:09:39 AM] avs [info]: 720x392p 1:1 @ 24000/1001 fps (cfr)
---[Information] [1/3/2020 8:09:39 AM] avs [info]: color matrix: undef
---[Information] [1/3/2020 8:09:39 AM] x264 [info]: using SAR=1/1
---[Information] [1/3/2020 8:09:39 AM] x264 [info]: using cpu capabilities: MMX2 SSE2Fast LZCNT SSSE3 SSE4.2
---[Information] [1/3/2020 8:09:39 AM] x264 [info]: profile High, level 4.1, 4:2:0, 8-bit
---[Information] [1/3/2020 8:09:39 AM] x264 [info]: cabac=1 ref=16 deblock=1:-3:-3 analyse=0x3:0x133 me=umh subme=10 psy=1 fade_compensate=0.00 psy_rd=1.00:0.15 mixed_ref=1 me_range=64 chroma_me=1 trellis=2 8x8dct=1 cqm=0 deadzone=21,11 fast_pskip=0 chroma_qp_offset=-3 threads=3 lookahead_threads=1 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 fgo=0 bframes=16 b_pyramid=2 b_adapt=2 b_bias=0 direct=3 weightb=1 open_gop=0 weightp=2 keyint=23 keyint_min=1 scenecut=40 intra_refresh=0 rc_lookahead=23 rc=crf mbtree=1 crf=18.0000 qcomp=0.60 qpmin=0:0:0 qpmax=69:69:69 qpstep=4 ip_ratio=1.40 aq=3:1.00 aq-sensitivity=10.00 aq-factor=1.00:1.00:1.00 aq2=0 aq3=0
---[Information] [1/3/2020 8:09:39 AM] x264 [info]: started at Fri Jan 03 08:09:38 2020
---[Error] [1/3/2020 8:13:26 AM] avs [error]: FFVideoSource: Out of bounds frame requested occurred while reading frame 5675
---[Error] [1/3/2020 8:13:26 AM] avs [error]: FFVideoSource: Out of bounds frame requested occurred while reading frame 5676
---[Information] [1/3/2020 8:13:27 AM] x264 [info]: frame I:256 Avg QP: 7.17 size: 16613
---[Information] [1/3/2020 8:13:27 AM] x264 [info]: frame P:1559 Avg QP:14.80 size: 8027
---[Information] [1/3/2020 8:13:27 AM] x264 [info]: frame B:3860 Avg QP:18.03 size: 3799
---[Information] [1/3/2020 8:13:27 AM] x264 [info]: consecutive B-frames: 9.2% 6.7% 14.2% 35.2% 15.9% 11.5% 2.8% 0.8% 0.0% 0.4% 0.8% 0.4% 0.0% 0.2% 0.0% 0.8% 0.9%
---[Information] [1/3/2020 8:13:27 AM] x264 [info]: mb I I16..4: 66.5% 18.2% 15.3%
---[Information] [1/3/2020 8:13:27 AM] x264 [info]: mb P I16..4: 3.6% 6.3% 3.4% P16..4: 11.8% 5.6% 4.7% 1.0% 0.4% skip:63.2%
---[Information] [1/3/2020 8:13:27 AM] x264 [info]: mb B I16..4: 0.1% 0.7% 0.9% B16..8: 12.4% 5.6% 2.4% direct: 1.4% skip:76.5% L0:40.9% L1:37.8% BI:21.3%
---[Information] [1/3/2020 8:13:27 AM] x264 [info]: 8x8 transform intra:32.3% inter:42.1%
---[Information] [1/3/2020 8:13:27 AM] x264 [info]: direct mvs spatial:99.5% temporal:0.5%
---[Information] [1/3/2020 8:13:27 AM] x264 [info]: coded y,uvDC,uvAC intra: 44.3% 48.1% 42.5% inter: 7.9% 7.6% 4.0%
---[Information] [1/3/2020 8:13:27 AM] x264 [info]: i16 v,h,dc,p: 73% 15% 6% 7%
---[Information] [1/3/2020 8:13:27 AM] x264 [info]: i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 15% 14% 21% 6% 8% 10% 8% 9% 9%
---[Information] [1/3/2020 8:13:27 AM] x264 [info]: i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 12% 11% 12% 8% 14% 13% 10% 10% 10%
---[Information] [1/3/2020 8:13:27 AM] x264 [info]: i8c dc,h,v,p: 67% 13% 11% 8%
---[Information] [1/3/2020 8:13:27 AM] x264 [info]: Weighted P-Frames: Y:1.3% UV:0.3%
---[Information] [1/3/2020 8:13:27 AM] x264 [info]: ref P L0: 61.1% 7.9% 15.3% 6.0% 3.5% 2.5% 1.6% 0.9% 0.6% 0.4% 0.2% 0.1% 0.0% 0.0% 0.0% 0.0%
---[Information] [1/3/2020 8:13:27 AM] x264 [info]: ref B L0: 83.0% 8.6% 4.0% 1.7% 1.1% 0.7% 0.5% 0.2% 0.1% 0.1% 0.0% 0.0% 0.0% 0.0%
---[Information] [1/3/2020 8:13:27 AM] x264 [info]: ref B L1: 96.8% 3.2%
---[Information] [1/3/2020 8:13:27 AM] x264 [info]: kb/s:1062.28
---[Information] [1/3/2020 8:13:27 AM] encoded 5675 frames, 24.88 fps, 1062.28 kb/s, 29.97 MB
---[Information] [1/3/2020 8:13:27 AM] x264 [info]: ended at Fri Jan 03 08:13:26 2020
---[Information] [1/3/2020 8:13:27 AM] x264 [info]: encoding duration 0:03:48
--[Information] [1/3/2020 8:13:27 AM] Job completed

video test: https://drive.google.com/open?id=1IjCojW2jgSLjJNaUwqKpJm74NlbwGrep

tebasuna51
3rd January 2020, 14:34
thanks, but still error with .vob file
...
---[Error] [1/3/2020 8:13:26 AM] avs [error]: FFVideoSource: Out of bounds frame requested occurred while reading frame 5675
---[Error] [1/3/2020 8:13:26 AM] avs [error]: FFVideoSource: Out of bounds frame requested occurred while reading frame 5676
...

video test: https://drive.google.com/open?id=1IjCojW2jgSLjJNaUwqKpJm74NlbwGrep

You must know something about VOB files.
If you load your IFO file over PgcDemux you can see the image attached.

Your video duration is 4:05.00, if you create one file per VID (Click Process! in the image) you obtain 2 VOB files:

VTS_01_1_001.VOB
------------------------------------------------------------------------------
VOB, 1 video track, 1 audio track, 0:03:57
1: MPEG2, 480p24 /1.001 (16:9) with pulldown flags
2: RAW/PCM, 2.0 channels, 16 bits, 48kHz

VTS_01_1_002.VOB
------------------------------------------------------------------------------
VOB, 1 video track, 0:00:08
1: MPEG2, 480i60 /1.001 (16:9)

The first one can be managed without problems with any decoder and obtain a perfect video 23.976 with the audio.

The second one is a true 29.970 credit (Sony) video without audio.
Seems than FFVideoSource crash when the final credit change video and audio parameters.

BTW MeGUI work fine for me, managing the correct video and don't offer me use ffms2 decoder, only DGIndex or DGIndexNV.

l33tmeatwad
3rd January 2020, 15:27
thanks, but still error with .vob file


video test: https://drive.google.com/open?id=1IjCojW2jgSLjJNaUwqKpJm74NlbwGrep
Any particular reason you are trying to use ffms2 and not DGIndex then mpeg2source?

kedautinh12
3rd January 2020, 17:14
Oh, thanks

kedautinh12
4th January 2020, 04:49
BTW MeGUI work fine for me, managing the correct video and don't offer me use ffms2 decoder, only DGIndex or DGIndexNV.

I see megui offer some .ts file use DGIndex but video encoded audio don't sync with video, same error with L-Smash
Video test: https://drive.google.com/a/my.smccd.edu/file/d/10S58IpaUueoRTEfo1cX1hJfxTFPp2I0Y/view?usp=drivesdk
After i was changed to ffms2 and audio can sync with video

Alternatively, megui offer some .ts with L-smash and it's work perfectly
Video test: https://drive.google.com/a/my.smccd.edu/file/d/1GzeVf1ecvarEz_d5TiK7Y4TNlpvkU-fw/view?usp=drivesdk

kedautinh12
4th January 2020, 09:32
Any particular reason you are trying to use ffms2 and not DGIndex then mpeg2source?

I see DGIndex too old (2010), i want found new index continue updated like ffms2 or l-smash to replaced DGIndex

StainlessS
4th January 2020, 11:49
I see DGIndex too old (2010), i want found new index continue updated like ffms2 or l-smash to replaced DGIndex

See here:- https://en.wiktionary.org/wiki/if_it_ain%27t_broke,_don%27t_fix_it,

Groucho2004
4th January 2020, 13:06
See here:- https://en.wiktionary.org/wiki/if_it_ain%27t_broke,_don%27t_fix_it,Mmm, so true.

I wonder what the kids these days qualify as "too old". Is there a formula? Something like (current time) - (last time I crapped my diapers)?

tebasuna51
4th January 2020, 13:07
I see megui offer some .ts file use DGIndex but video encoded audio don't sync with video, same error with L-Smash...

Please don't cross posts.
Like the questions are related with MeGUI please read that thread:
https://forum.doom9.org/showthread.php?p=1894677#post1894677

(I leave the post here because the links are broken in the other thread)

LigH
6th January 2020, 10:16
DGMPGDec is just as "too old" as MPEG-2 video :p

manolito
14th January 2020, 07:49
Compiled the last official stable release with FFMPEG 4.2.2 libs, figured a few people may be interested in having it so here it is:


Just tested this build using some HEVC sources, but it has a bad regression concerning HEVC seeking.

The build I use normally is from STvG from Nov 2019, and HEVC seeking works with this build. The meatwad build does not include the fix for seeking, it is unusable for HEVC sources.

lansing
15th January 2020, 11:00
Non utf-8 file path support with DGIndex after all these years seems to be a good reason to hop onto another train.

LigH
15th January 2020, 16:30
If just any other "train" supported playlists like d2v indexing across a set of VOB segments ... but neither FFMS2 nor L-SMASH Works do. So you need to extract a PGC as continuous file (e.g. using PGCDemux or any DVD ripper with "PGC VOB" output or M2V video demux).

kedautinh12
16th January 2020, 04:28
Non utf-8 file path support with DGIndex after all these years seems to be a good reason to hop onto another train.

that why i like source filters continued update

l33tmeatwad
16th January 2020, 18:32
Non utf-8 file path support with DGIndex after all these years seems to be a good reason to hop onto another train.
Does D2V Witch support non-utf8 file paths?

videoh
16th January 2020, 18:39
Non utf-8 file path support with DGIndex after all these years seems to be a good reason to hop onto another train. There's no reason that can't be updated as per DGDecNV. I'll try to find time for it.

Matias
26th January 2020, 04:00
Is it possible to repair error like this?
https://i.imgur.com/F9Bn5JC.png

Myrsloik
26th January 2020, 11:53
Is it possible to repair error like this?
https://i.imgur.com/F9Bn5JC.png
Only by cutting away the bits with a different format.

I'll probably implement it in BestAudioSource some day.

gpower2
8th February 2020, 10:23
Hey people! Is there any news about an official release for FFMS2?
I see 202 commits after the latest release in GitHub.

Nico8583
14th February 2020, 11:24
Hi ! Same question than gpower2, is there a new version for FFMS2 ? Thank you !

gpower2
4th April 2020, 20:16
Hey people, since no one seems to have the time for providing a new build for our beloved FFMS2 lib, I decided to make the best out of the COVID quarantine and try to have a go for it.

It was not easy, especially for someone who doesn't compile C/C++ open source cross platform projects often, like me. :P
But at last I managed to have a fully working (and quite a speedy one) x64 build!

ffms2-0628fe6-win64-20200404.7z (https://bit.ly/2UIFKGU)

I only needed a x64 one, if I manage to find the time I'll provide with a x86 one, but this is one time expensive process, so don't get your hopes up.

Enjoy people! :)


Build details for the next one who tries to do that:

FFMpeg

branch master, commit: a6e56d12a413013d3a4b39f670e5495805965a67 (https://github.com/FFmpeg/FFmpeg/commit/a6e56d12a413013d3a4b39f670e5495805965a67)
April 3, 2020

Build tools:

MSYS2 x86_64 20190524
Latest MSYS2 packages (pacman -S make pkg-config diffutils nasm)
VS 2019 16.5.2 Community Edition


Build instructions:

Download latest MSYS2 from http://msys2.github.io/
Open Visual C++ command prompt with environment set for 64-bit MSVC compilation. In my case it is called "x64 Native Tools Command Prompt for VS 2019".
Now open MSYS console from within the MSVC command prompt:
C:\msys64\msys2_shell.cmd -use-full-path
NOTE: You must specify "-use-full-path" in order for the MSYS2 console to know the PATH from the VS command prompt
Use "pacman" in MSYS2 console to install the packages needed for building FFMpeg
pacman -S make pkg-config diffutils nasm
Configure FFmpeg - run following command in MSYS console:
./configure --arch=x86_64 --target-os=win64 --toolchain=msvc
Build the binaries - run following command in MSYS console:
make
Install the binaries - run following command in MSYS console:
make install
NOTE: By default they should end up in C:\msys64\usr\local



ZLib

branch master, commit: cacf7f1d4e3d44d871b605da3b647f07d718623f (https://github.com/madler/zlib/commit/cacf7f1d4e3d44d871b605da3b647f07d718623f)
Jan 15, 2017 (zlib 1.2.11)

Build tools:

Build from contrib\vstudio\vc14\zlibvc.sln in VS 2019 16.5.2 Community Edition in Release x64 configuration
Used the contrib\vstudio\vc14\x64\ZlibStatRelease\zlibstat.lib



FFMS2

branch master, commit: 0628fe69f014c398d1c5d15d99934a88a4a65c3b (https://github.com/FFMS/ffms2/commit/0628fe69f014c398d1c5d15d99934a88a4a65c3b)
Mar 30, 2020

Build tools:

Build from build-msvc\ffms2.sln in VS 2019 16.5.2 Community Edition in Release x64 configuration


MSVC Project changes:

WindowsTargetPlatformVersion: 10.0.16299.0 => 10.0
PlatformToolset: v141 => v142
Added "../../zlib" in IncludePath
Added "../../zlib/contrib/vstudio/vc14/x64/ZlibStatRelease" in LibraryPath
Added "bcrypt.lib" in Linker AdditionalDependencies
Changed "zlib.lib" to "zlibstat.lib" in Linker AdditionalDependencies
Added "../../zlib/contrib/vstudio/vc14/x64/ZlibStatRelease;../../ffmpeg64/lib" in Linker AdditionalLibraryDirectories


Links that helped me fill the blanks:
http://ffmpeg.org/platform.html#Windows
https://ffmpeg.zeranoe.com/forum/viewtopic.php?f=5&t=7497

tolias63
4th April 2020, 20:32
Oh, nice work! Thanks, Gpower2!

filler56789
4th April 2020, 21:34
FFMS2 latest x64 build

:goodpost: and :thanks:

Stereodude
5th April 2020, 04:01
Is ffms2 supposed to be frame accurate when seeking?

StvG
5th April 2020, 07:31
Another ffms2 update (https://cloud.owncube.com/s/nSEQsddidmFYyCX):
- ffms2@bda9eeb;
- ffmpeg n4.3@72be5d4661;
- zlib 1.2.11;
- dav1d 0.6.0.

Myrsloik
5th April 2020, 10:20
Is ffms2 supposed to be frame accurate when seeking?

Yes, except when it's not. It mostly depends on the container and a bit on the codec.

StainlessS
5th April 2020, 15:37
Yes, except when it's not.

Or to put it another way,

No, except when it is. :)

kedautinh12
11th April 2020, 02:27
ffms2-0628fe6-win64-20200404.7z (https://bit.ly/2UIFKGU)


same error with StvG ver

video test: https://drive.google.com/file/d/1GzeVf1ecvarEz_d5TiK7Y4TNlpvkU-fw/view?usp=sharing

log:

-[Information] Versions
--[Information] MeGUI: 2913 x64
--[Information] MeGUI Debug Data: available
--[Information] Update Check: development update server
-[Information] Operating System: Windows 10 Pro 1909 x64 (10.0.18363.720)
-[Information] .NET Framework: 4.0 (4.0.0.0)
-[Information] .NET Framework: 4.8 (4.8.03752)
-[Information] Microsoft Visual C++ 2005 x64: 8.0.61000
-[Information] Microsoft Visual C++ 2005 x86: 8.0.61001
-[Information] Microsoft Visual C++ 2010 x64: 10.0.40219
-[Information] Microsoft Visual C++ 2010 x86: 10.0.40219
-[Information] Microsoft Visual C++ 2012 x64: 11.0.61030
-[Information] Microsoft Visual C++ 2012 x86: 11.0.61030
-[Information] Microsoft Visual C++ 2013 x64: 12.0.40664
-[Information] Microsoft Visual C++ 2013 x86: 12.0.40664
-[Information] Microsoft Visual C++ 2015-2019 x64: 14.24.28127
-[Information] Microsoft Visual C++ 2015-2019 x86: 14.24.28127
-[Information] Redistributables
-[Information] DPI: 100% (96/96)
-[Information] Resolution: 1366x768
-[Information] Primary Screen: True
-[Information] Monitor 1
--[Information] System Information
-[Information] Update detection
-[Information] Haali Media Splitter: 1.13.138.14 (14-04-2013)
-[Information] Haali DSS2: 2.0.0.13 (01-01-2019)
-[Information] ICSharpCode.SharpZipLib: 0.85.5.452 (07-08-2008)
-[Information] MediaInfo: 18.05.0.0 (08-05-2018)
-[Information] SevenZipSharp: 0.64.3890.29348 (02-01-2011)
-[Information] 7z: 9.20 (18-11-2010)
--[Information] Component Information
-[Information] Version: 1.0.2847.0
-[Information] Date: 06-05-2018
-[Information] Interface: 3
-[Information] AviSynth Wrapper
-[Information] AviSynth Status: ignored as portable build is forced
-[Information] AviSynth
--[Information] [4/11/2020 8:02:09 AM] Cannot use update server http://megui.org/auto/. Reason: Update server is not available
--[Information] [4/11/2020 8:02:09 AM] Cannot use update server http://megui.tmebi.de/test/. Reason: Update server is not available
--[Information] [4/11/2020 8:02:09 AM] Using cached update config and server: http://megui.tmebi.de/test/
--[Information] [4/11/2020 8:02:09 AM] No package requires an update
-[Information] File Version: 3.5
-[Information] File Date: 02-04-2020
-[Information] File Name: AviSynth+ 3.5 (r3106, 3.5, x86_64)
-[Information] File Path: e:\megui-2913-64\avisynth.dll
-[Information] AviSynth Version: AviSynth+ 3.5 (r3106, 3.5, x86_64)
-[Information] AviSynth+: true
-[Information] AviSynth MT: true
-[Information] AviSynth Status: active
-[Information] AviSynth portable
--[Information] AviSynth Information
-[Information] FileIndexer
--[Information] [4/11/2020 8:02:25 AM] MediaInfo
---[Information] File: C:\Users\84945\Downloads\Video for test\Hikoutei - King Gnu.ts
-[Information] Format: MPEG-TS
-[Information] FileSize: 147849216
-[Information] PlayTime: 00:04:22.912
---[Information] General
-[Information] ID: 4352
-[Information] StreamOrder: 0-0
-[Information] CodecID: 27
-[Information] Format: AVC
-[Information] FormatInfo: Advanced Video Codec
-[Information] Width: 1440
-[Information] Height: 1080
-[Information] FrameCount: 7852
-[Information] FrameRate: 29.970
-[Information] Duration: 00:04:21.995
-[Information] ScanType: Interlaced
-[Information] Bits Depth: 8
-[Information] AspectRatio: 1.778
-[Information] AspectRatioString: 16:9
-[Information] PixelAspectRatio: 1.333
-[Information] Delay: 1079.911
---[Information] Video
-[Information] ID: 4353
-[Information] StreamOrder: 0-1
-[Information] CodecID: 15
-[Information] Format: AAC
-[Information] FormatVersion: Version 2
-[Information] FormatInfo: Advanced Audio Codec
-[Information] FormatProfile: LC
-[Information] Muxing Mode: ADTS
-[Information] SamplingRate: 48000
-[Information] SamplingRateString: 48.0 kHz
-[Information] Channels: 2
-[Information] ChannelsString: 2 channels
-[Information] ChannelPositionsString2: 2/0/0
-[Information] BitRateMode: VBR
-[Information] Delay: 1079.911
-[Information] [4/11/2020 8:02:26 AM] The language information is not available for this track. The default MeGUI language has been selected.
---[Information] Audio
-[Information] Log for job1 (idx, Hikoutei - King Gnu.ts -> Hikoutei - King Gnu.ts.ffindex)
--[Information] [4/11/2020 8:02:28 AM] Started handling job
--[Information] [4/11/2020 8:02:28 AM] Preprocessing
--[Information] [4/11/2020 8:02:28 AM] Job command line: "E:\MeGUI-2913-64\tools\ffms\ffmsindex.exe" -t -1 -f "C:\Users\84945\Downloads\Video for test\Hikoutei - King Gnu.ts" "C:\Users\84945\Downloads\Video for test\Hikoutei - King Gnu.ts.ffindex"
--[Information] [4/11/2020 8:02:28 AM] Process started
--[Information] [4/11/2020 8:02:28 AM] Standard output stream
--[Information] [4/11/2020 8:02:28 AM] Standard error stream
---[Information] [4/11/2020 8:02:31 AM] Writing index... done.
--[Information] [4/11/2020 8:02:35 AM] MediaInfo
---[Information] File: C:\Users\84945\Downloads\Video for test\Hikoutei - King Gnu.ts.ffindex
-[Information] FileSize: 85117
---[Information] General
--[Information] [4/11/2020 8:02:35 AM] Postprocessing
---[Information] [4/11/2020 8:02:40 AM] Deleting intermediate files
--[Information] [4/11/2020 8:02:40 AM] Job completed
-[Information] AVS Script Creator
--[Warning] [4/11/2020 8:02:40 AM] Could not read frame: FFVideoSource: Out of bounds frame requested
--[Warning] [4/11/2020 8:02:41 AM] Could not read frame: FFVideoSource: Out of bounds frame requested

kedautinh12
11th April 2020, 02:30
FFMS2 2.23.1 (w/ FFmpeg 4.2.2)
Static Libs Build (x86 & x64) (http://www.mediafire.com/file/yyabrt1jkmmlvsn) | Sources (https://www.mediafire.com/folder/3tv37w2c9ibps/Source)


use normally with this ver

gpower2
11th April 2020, 11:34
same error with StvG ver

video test: https://drive.google.com/file/d/1GzeVf1ecvarEz_d5TiK7Y4TNlpvkU-fw/view?usp=sharing

log:

I just provided a build with the latest versions of all dependencies at the time. I haven't tampered with the code in the slightest.

I guess it's a regression bug or something.

However, for .ts files, I recommend using LSMASH source filter, since it seems to be frame accurate instead of FFMS2, at least in my experience. ;)

Nik92
9th May 2020, 09:05
Hi,

I have a captured video in HuffYUV and when I open it using FFmpegSource2 in Avisynth+ some frames are dropped which leads to audio to be out of sync.

No such issue when using AVISource, 319405 frames total, 25 fps:
https://forum.doom9.org/attachment.php?attachmentid=17330&stc=1&d=1589011239

But with FFmpegSource2 319008 frames total, 397 frames are dropped, 24.969 fps:

https://forum.doom9.org/attachment.php?attachmentid=17331&stc=1&d=1589011332

Also no dropped frames if I open with FFmpegSource2 the same video but encoded in FFV1.

Is it just me or FFmpegSource2 is not working correctly with HuffYUV?

Thanks

Myrsloik
9th May 2020, 10:53
Hi,

I have a captured video in HuffYUV and when I open it using FFmpegSource2 in Avisynth+ some frames are dropped which leads to audio to be out of sync.

No such issue when using AVISource, 319405 frames total, 25 fps:
https://forum.doom9.org/attachment.php?attachmentid=17330&stc=1&d=1589011239

But with FFmpegSource2 319008 frames total, 397 frames are dropped, 24.969 fps:

https://forum.doom9.org/attachment.php?attachmentid=17331&stc=1&d=1589011332

Also no dropped frames if I open with FFmpegSource2 the same video but encoded in FFV1.

Is it just me or FFmpegSource2 is not working correctly with HuffYUV?

Thanks

Huffyuv in avi should always work perfectly. Which ffms2 version did you try?

Does the captured file by any chance contain exactly 397 dropped frames?

zorr
9th May 2020, 13:43
My experience with ffmpegsource and dropped frames in Huffyuv clips is that they are skipped (tests done with Vapoursynth's core.ffms2.Source).

VirtualDub however shows them as duplicate frames so what I did was preprocess the video with VirtualDub so that the dropped frames are included as duplicates. It would be nice if there was a more elegant way.

Nik92
9th May 2020, 23:05
Huffyuv in avi should always work perfectly. Which ffms2 version did you try?
I tried with 2.23.1 and the one provided by gpower2 a few posts earlier.
Does the captured file by any chance contain exactly 397 dropped frames?

I'm not sure how to get the amount of dropped frames but when capturing I think I remember there was this number (or very close) of inserted frames reported by VirtualDub.


My experience with ffmpegsource and dropped frames in Huffyuv clips is that they are skipped (tests done with Vapoursynth's core.ffms2.Source).

VirtualDub however shows them as duplicate frames so what I did was preprocess the video with VirtualDub so that the dropped frames are included as duplicates. It would be nice if there was a more elegant way.
Could you please share what preprocessing was done with VirtualDub?

zorr
10th May 2020, 20:44
Could you please share what preprocessing was done with VirtualDub?

Load the video into VirtualDub and set the compression to Huffyuv. Select the "Fast recompress" option at the Video menu. Then save as AVI.

The resulting file no longer has dropped frames (at least VirtualDub cannot find them anymore) and they are replaced as duplicate frames.

videoh
10th May 2020, 21:28
AVI/VFW is so 90s.

stranno
22nd May 2020, 17:35
I have been using FFMS2 + ProRes for years and everything works fine. But now I have switched to h264/h265 and FFMS2 struggles with the audio. Seeking, using any player (MPC-HC), and trimming, using NVEncc, takes A LOT of time.

Using FFVideoSource alone I have no problems at all, it seeks perfectly fine and it has a top-notch performance. Extracing the audio track and loading it using FFAudioSource also works. But loading the audio track from the MKV makes the decoder to struggle like hell.

I'm using the latest StvG build (from this page of the thread) but I also have tried more builds. Same problems.

Video seems to be fine, its MKV + h264 + AAC LC ADTS.

Any idea?

Myrsloik
22nd May 2020, 19:12
I have been using FFMS2 + ProRes for years and everything works fine. But now I have switched to h264/h265 and FFMS2 struggles with the audio. Seeking, using any player (MPC-HC), and trimming, using NVEncc, takes A LOT of time.

Using FFVideoSource alone I have no problems at all, it seeks perfectly fine and it has a top-notch performance. Extracing the audio track and loading it using FFAudioSource also works. But loading the audio track from the MKV makes the decoder to struggle like hell.

I'm using the latest StvG build (from this page of the thread) but I also have tried more builds. Same problems.

Video seems to be fine, its MKV + h264 + AAC LC ADTS.

Any idea?

The audio support is bad. If you can tolerate slightly worse performance give bestaudiosource a try. Otherwise keep demuxing...

stranno
22nd May 2020, 19:35
The audio support is bad. If you can tolerate slightly worse performance give bestaudiosource a try. Otherwise keep demuxing...
Thank you Myrsloik. It does the job perfectly fine and performance hit is tolerable. Is there room for performance improvements? Are you still working on it? Would indexing allow better performance?

Myrsloik
22nd May 2020, 20:47
Thank you Myrsloik. It does the job perfectly fine and performance hit is tolerable. Is there room for performance improvements? Are you still working on it? Would indexing allow better performance?

1. Nope, the performance basically is what it is. Don't expect it to change at all.
2. Yes.
3. The whole idea is to not index and simply sacrifice a bit of cpu time for linear decoding. If you start indexing you end up with FFMS2.

stranno
22nd May 2020, 21:47
1. Nope, the performance basically is what it is. Don't expect it to change at all.
2. Yes.
3. The whole idea is to not index and simply sacrifice a bit of cpu time for linear decoding. If you start indexing you end up with FFMS2.
Again, many thanks. I will stick with bestaudiosource.

wonkey_monkey
24th May 2020, 19:41
As I'm having problems getting DGDecNV to work on my new computer, I'm trying ffmpegsource on a 30Gb blu-ray rip (demuxed .264 file). It works, but it takes forever to open each time (15 minutes or so. It's not re-indexing as far as I can tell; I created the .ffindex file on the command line and its modified date hasn't changed).

Is this just how slow it is with such large files?

stax76
24th May 2020, 19:59
Normally with MKV both ffms2 and l-smash are super fast indexing, staxrip uses LWLibavVideoSource for raw files by default, probably better.

videoh
24th May 2020, 20:16
Is this just how slow it is with such large files? Sounds like something is sideways. Shouldn't be like that. Happy to help with DGDecNV if you want to open a new thread or visit my forum. Laptops can be problematic. :sly: But MX150 looks like a fine GPU. Let's see if we can sort things out for you.

wonkey_monkey
24th May 2020, 21:52
Sounds like something is sideways. Shouldn't be like that. Happy to help with DGDecNV if you want to open a new thread or visit my forum. Laptops can be problematic. :sly: But MX150 looks like a fine GPU. Let's see if we can sort things out for you.

Thanks - already done, as I guess you know, unless you are somehow GPU-psychic.

As for ffmpegsource, I just tried with a 780Mb .m2ts file. It indexed in 30 seconds or so, and subsequent opens were instant. I'll now try with a 39Gb .m2ts...

videoh
24th May 2020, 22:06
unless you are somehow GPU-psychic. All seeing, all knowing.

wonkey_monkey
24th May 2020, 23:35
The 39Gb M2TS file took 17 minutes to index the first time, then opened instantly the next time.

I went back to the 30Gb .264 file, renamed the existing index file (created on the command line: 609,535 bytes), and opened the script in VirtualDub. It took nearly 30 minutes, created an index file which is 632,958 bytes, but still didn't open instantly the next time (I let it got for 10 minutes before giving up).

I've now remuxed the .264 into a .ts, and it's working as expected, so I guess it was just something about that .264 file.

videoh
25th May 2020, 00:23
I guess it was just something about that .264 file. Sounds very doubtful, especially if it opened fine the first time. Sounds like an index management issue for elementary stream files.