Coder Social home page Coder Social logo

Comments (8)

cr08 avatar cr08 commented on August 12, 2024

As a suggestion it may be simpler to go to the command line options I used in the following comment or some equivalent: #24 (comment) Essentially it should copy all streams over from the input file regardless of type and just ignore the original video stream (since we are upscaling and providing a new copy of course). I'm not sure if there's any reason we should potentially be ignoring certain streams and not just keeping the original intact 1:1 save for the upscaled video.

from video2x.

k4yt3x avatar k4yt3x commented on August 12, 2024

@cr08 ok. I'll follow your suggestions and try it out.

from video2x.

k4yt3x avatar k4yt3x commented on August 12, 2024

I have made a test with your solution, but it didn't seem to copy anything over besides the video stream.

-map 1:v:0 -map 0 -c copy -map -0:v

from video2x.

cr08 avatar cr08 commented on August 12, 2024

I had a look through again and it may be the input videos are flipped around in the ffmpeg command. Right now the no_audio.mp4 is coming first. So either the above options need to be flipped to

-map 0:v:0 -map 1 -c copy -map -1:v

or flip around the input -i parameters so the no_audio.mp4 comes second.

I'm running a quick test on my end to confirm.

from video2x.

k4yt3x avatar k4yt3x commented on August 12, 2024

Oops you're right. I changed it to

-map 0:v:0? -map 1? -c copy -map -1:v?

I don't know if it's necessary to add the ?s, is it?
Everything is looking good right now though. All streams have been copied over.

from video2x.

cr08 avatar cr08 commented on August 12, 2024

Theoretically the question marks shouldn't be needed. Based on how I am reading the documentation it is only necessary if there is a possibility of that map not existing so the command doesn't outright fail, it just ignores that map.

-map 0:v:0?
^ We know the input video track is going to exist there from the no_audio.mp4 file

-map 1?
^ We know the source input file should still exist at this stage and the map is just saying to grab everything regardless of track type. The only POTENTIAL issue I could see is if someone deletes the input file mid-way through running the script but I don't know why they would?

-map -1:v?
^ Much like the last map, the original source file we know should have a video track that needs to be cancelled out.

With that all said there's nothing harmful leaving the question marks in there, just extraneous characters.

from video2x.

cr08 avatar cr08 commented on August 12, 2024

And confirmed on my end that swapping those around works just fine with my test content.

from video2x.

k4yt3x avatar k4yt3x commented on August 12, 2024

Changes committed. It should be working now.

from video2x.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.