Closed FranceBB closed 8 months ago
I am unable to test right now but can you confirm the issue does NOT occur with 20240112 1167.0.0.0 as I would like to rule that out.
Thanks
Try the attached version.
Amazing, thank you so much asd, as always. The fix worked like a charm, I just tested it.
@Asd-g:
This issue still exists on build 1194.0.0.0
It's always re-create LWI file and not use the exists LWI
For example my AVS:
a=LWLibavAudioSource("source.mkv", 1) c=LWLibavVideoSource("source.mkv", format="YUV420P8", prefer_hw=1) a=AssumeFPS(a, 24000, 1001) c=AssumeFPS(c, 24000, 1001) AudioDub(c, a)
I already had existsed LWI file but it still re-create it
Try the script with AVSMeter - running few times avsmeter64 scripts.avs -o -timelimit=2
should create lwi index file only for the first time. Or if you prefer ffmpeg - run few time ffmpeg -i script.avs -c copy -f null -
.
@Asd-g
I re-check with your CLI and confirm that the LWI file not be re-created
Then, I check my encode flow and found out First, I review the video source file with this AVS script on AvsPmod:
LWLibavVideoSource("E:\Download\z\source.mkv", prefer_hw=1) AssumeFPS(24000, 1001)
Then, it created new LWI file.
After that I encoded with this AVS script:
a=LWLibavAudioSource("source.mkv", 1) c=LWLibavVideoSource("source.mkv", format="YUV420P8", prefer_hw=1) a=AssumeFPS(a, 24000, 1001) c=AssumeFPS(c, 24000, 1001) AudioDub(c, a)
And it recreated LWI file.
I am not sure this is issue or this is feature of L-SMASH.
Can you check if you are using the same dll binary? Like maybe one of the app is 32 bit and the other is 64 bit?
@msg7086 @Asd-g
I checked that I only install 64 bit version of AVS+ and 64 bit L-SMASH
Just to make sure, I empty folder plugins
and plugins+
and it still happend
Step to reproduce:
s.avs
and s2.avs
:
s.avs
:LWLibavVideoSource("source.mkv", prefer_hw=1) AssumeFPS(24000, 1001)
s2.avs
:
c=LWLibavVideoSource("source.mkv", prefer_hw=1) c=AssumeFPS(c, 24000, 1001) a=LWLibavAudioSource("source.mkv", 1) a=AssumeFPS(a, 24000, 1001) AudioDub(c, a)
avsmeter s.avs -o -timelimit=2
first and avsmeter s2.avs -o -timelimit=2
after thatResult: it still create LWI file
It's expected behavior. With script s.avs
you create index file with no active audio stream. With script s2.avs
you create index file with active audio stream.
Compare the index files from both files to see the diff.
@Asd-g
I understood, thank for your help
Starting with version 20240304 1170.0.0.0 there's a regression about using the lwi files. The version before the latest release was checking whether there was an lwi file in the same directory as the file and if it was written with the same version of LWLibav. If it was written with an older version, then it would recreate the lwi index, otherwise it would use the one it found. In this new version, however, it recreates the lwi file every single time, not just with AVSPmod mod but also with ffmpeg and any other application. For instance, in this very same unchanged script, we have two different command lines calling ffmpeg and it's recreating the index files both times:
Setting cache=true doesn't affect it as it keeps recreating it anyway and it's set to true by default anyway even when it's left unspecified. I tried with cachefile but it is still recreating it:
Even changing the disk didn't change a thing:
adding a simple:
tweak(sat=1.31, dither=true)
as an example, makes it recreate the .lwi