mifi / lossless-cut

The swiss army knife of lossless video/audio editing
https://losslesscut.app/
GNU General Public License v2.0
27.26k stars 1.32k forks source link

(Regression) Drag-and-drop another file causes it to be reported as not supported #1338

Closed VL4DST3R closed 2 years ago

VL4DST3R commented 2 years ago

I have a lot of issues to go through, so in order to make it easier for me to help you, I ask that you please try these things first

Operating System

Windows 10

Steps to reproduce

  1. open a recording made by shadowplay via drag-and-drop
  2. wait for it to load, then drag and drop another recording (or even the same file again)

I've been using lossless cut for a few years now to losslessly trim my nvidia shadowplay recordings to the bits i'm interested in.

However recently i've updated to the latest (currently 3.46.2) version and i noticed an issue: When i open individual files (open the program, drag-and-drop a file) it works as expected, but if i drag another video over a pre-existing session (and choose open the new file) i get "File not natively supported.". If i close the program down, open it again and go straight to opening my second video, it works as intended. This was never an issue before and i could "chain" edits this way without closing the program in-between with no problem.

Expected behavior

To switch from working on one file to another properly

Actual behavior

Lossless Cut switches to low res "unsupported" preview even though its clearly supported

Share log

main.f18f3ad4.js:2 Version 3.46.2 main.f18f3ad4.js:2 ffmpeg -hide_banner -f lavfi -i 'nullsrc=s=256x256:d=1' -f null - main.f18f3ad4.js:2 userOpenFiles main.f18f3ad4.js:2 G:\ShadowPlay\Project Zomboid\test1.mp4 main.f18f3ad4.js:2 loadMedia G:\ShadowPlay\Project Zomboid\test1.mp4 undefined undefined main.f18f3ad4.js:2 state reset main.f18f3ad4.js:2 ffprobe -of json -show_chapters -show_format -show_entries stream -i 'G:\ShadowPlay\Project Zomboid\test1.mp4' -hide_banner main.f18f3ad4.js:2 formats mov,mp4,m4a,3gp,3g2,mj2 main.f18f3ad4.js:2 fileType detected format {"ext":"mp4","mime":"video/mp4"} main.f18f3ad4.js:2 onDurationChange 27.157 main.f18f3ad4.js:2 ffprobe -v error -read_intervals '0%30' -show_packets -select_streams 0 -show_entries 'packet=pts_time,flags' -of json 'G:\ShadowPlay\Project Zomboid\test1.mp4' DevTools failed to parse SourceMap: file:///E:/Programs/Lossless%20%20Cut/resources/app.asar/build/static/js/main.f18f3ad4.js.map DevTools failed to parse SourceMap: file:///E:/Programs/Lossless%20%20Cut/resources/app.asar/build/main.js.map DevTools failed to parse SourceMap: file:///E:/Programs/Lossless%20%20Cut/resources/app.asar/build/signals.js.map DevTools failed to parse SourceMap: file:///E:/Programs/Lossless%20%20Cut/resources/app.asar/build/core.js.map DevTools failed to parse SourceMap: file:///E:/Programs/Lossless%20%20Cut/resources/app.asar/build/realtime.js.map DevTools failed to parse SourceMap: file:///E:/Programs/Lossless%20%20Cut/resources/app.asar/build/cue.js.map DevTools failed to parse SourceMap: file:///E:/Programs/Lossless%20%20Cut/resources/app.asar/build/index.js.map DevTools failed to parse SourceMap: file:///E:/Programs/Lossless%20%20Cut/resources/app.asar/build/node.js.map DevTools failed to parse SourceMap: file:///E:/Programs/Lossless%20%20Cut/resources/app.asar/build/utf8.js.map DevTools failed to parse SourceMap: file:///E:/Programs/Lossless%20%20Cut/resources/app.asar/build/match.js.map DevTools failed to parse SourceMap: file:///E:/Programs/Lossless%20%20Cut/resources/app.asar/build/unicode.js.map DevTools failed to parse SourceMap: file:///E:/Programs/Lossless%20%20Cut/resources/app.asar/build/mbcs.js.map DevTools failed to parse SourceMap: file:///E:/Programs/Lossless%20%20Cut/resources/app.asar/build/sbcs.js.map DevTools failed to parse SourceMap: file:///E:/Programs/Lossless%20%20Cut/resources/app.asar/build/iso2022.js.map DevTools failed to parse SourceMap: file:///E:/Programs/Lossless%20%20Cut/resources/app.asar/build/command.js.map DevTools failed to parse SourceMap: file:///E:/Programs/Lossless%20%20Cut/resources/app.asar/build/cuesheet.js.map DevTools failed to parse SourceMap: file:///E:/Programs/Lossless%20%20Cut/resources/app.asar/build/static/css/main.6a515823.css.map main.f18f3ad4.js:2 userOpenFiles main.f18f3ad4.js:2 G:\ShadowPlay\Project Zomboid\test2.mp4 main.f18f3ad4.js:2 loadMedia G:\ShadowPlay\Project Zomboid\test2.mp4 undefined undefined main.f18f3ad4.js:2 state reset main.f18f3ad4.js:2 ffprobe -of json -show_chapters -show_format -show_entries stream -i 'G:\ShadowPlay\Project Zomboid\test2.mp4' -hide_banner main.f18f3ad4.js:2 formats mov,mp4,m4a,3gp,3g2,mj2 main.f18f3ad4.js:2 fileType detected format {"ext":"mp4","mime":"video/mp4"} main.f18f3ad4.js:2 onDurationChange 27.157 main.f18f3ad4.js:2 onVideoError PIPELINE_ERROR_DECODE: VDA Error 4 3 (anonymous) @ main.f18f3ad4.js:2 Ve @ main.f18f3ad4.js:2 Ke @ main.f18f3ad4.js:2 (anonymous) @ main.f18f3ad4.js:2 Ar @ main.f18f3ad4.js:2 Nr @ main.f18f3ad4.js:2 (anonymous) @ main.f18f3ad4.js:2 Le @ main.f18f3ad4.js:2 (anonymous) @ main.f18f3ad4.js:2 Mr @ main.f18f3ad4.js:2 Jt @ main.f18f3ad4.js:2 Zt @ main.f18f3ad4.js:2 main.f18f3ad4.js:2 Trying to create preview main.f18f3ad4.js:2 readFormatData G:\ShadowPlay\Project Zomboid\test2.mp4 main.f18f3ad4.js:2 ffprobe -of json -show_format -i 'G:\ShadowPlay\Project Zomboid\test2.mp4' -hide_banner main.f18f3ad4.js:2 html5ifyAndLoad {speed: "fastest", hasVideo: true, hasAudio: true, usesDummyVideo: true} main.f18f3ad4.js:2 Making HTML5 friendly dummy {filePathArg: "G:\ShadowPlay\Project Zomboid\test2.mp4", outPath: "G:\ShadowPlay\Project Zomboid\test2-html5ified-dummy.mkv"} main.f18f3ad4.js:2 readFormatData G:\ShadowPlay\Project Zomboid\test2.mp4 main.f18f3ad4.js:2 ffprobe -of json -show_format -i 'G:\ShadowPlay\Project Zomboid\test2.mp4' -hide_banner main.f18f3ad4.js:2 ffmpeg -hide_banner -f lavfi -i 'anullsrc=channel_layout=stereo:sample_rate=44100' -t '27.157' -acodec flac -y 'G:\ShadowPlay\Project Zomboid\test2-html5ified-dummy.mkv' main.f18f3ad4.js:2 ffprobe -v error -read_intervals '0%30' -show_packets -select_streams 0 -show_entries 'packet=pts_time,flags' -of json 'G:\ShadowPlay\Project Zomboid\test2.mp4' main.f18f3ad4.js:2 main.f18f3ad4.js:2 onDurationChange 27.157

mifi commented 2 years ago

Thanks for your detailed report. Seems like something unstable with the <video> player. It reports PIPELINE_ERROR_DECODE the second time you load the file. For convenience, losslesscut will automatically use the preview when encountering such an error. Though I think it might make sense to instead ask the user what to do when encountering this error. I'll close it as a dup of #1115

See if disable "Auto convert to supported format" in settings helps

VL4DST3R commented 2 years ago

Tried and it doesn't help sadly, i just get a green screen with no seek controls. At the very least i don't have to delete the generated file this way, which seems to take priority when opening said file on a fresh instance of the program, requiring you to delete it to get it to load properly. I'm hoping for an actual fix.

EDIT: on another note, since this is quite a nuisance given my workflow, any idea what version caused this to start happening? I'd like to revert to something prior to that for the time being.

mifi commented 2 years ago

Ok, if you get a green screen when loading the second file, then it's definitely a bug in Chromium/Electron. It might get fixed once we upgrade electron to newest #714

VL4DST3R commented 2 years ago

I'm not familiar with your release schedule, any idea when that will happen?

mifi commented 2 years ago

EDIT: on another note, since this is quite a nuisance given my workflow, any idea what version caused this to start happening? I'd like to revert to something prior to that for the time being.

electron was upgraded to v8 from v7 here: https://github.com/mifi/lossless-cut/blame/3b408781b9eaa149c470b57ba01212a87c61f8c9/package.json

So I think any version before that might behave differently with your file, but it's about 3 years ago so you'd lose a lot of features too.

I'm not familiar with your release schedule, any idea when that will happen?

I don't have any fixed schedule and currently very busy with a lot of other projects. #714 is a big task so it's hard to say how long it will take, but that task is definitely the highest priority now for a lot of reasons.

mifi commented 2 years ago

another thing I'm not sure if you tried is to close the current file before opening the new one. does that lead to the same green screen?

VL4DST3R commented 2 years ago

Thanks for all the feedback but sadly i'm out of town for the weekend, so it may take a bit until i can test your suggestions. That being said, very grateful for the prompt response and the help with this! Will come back at you the moment i get the time.

VL4DST3R commented 1 year ago

Hey, just wanted to pop back in and say that all seems to be good on 3.47.1, whether you actively fixed it or not XD