Coder Social home page Coder Social logo

Comments (4)

murlakatamenka avatar murlakatamenka commented on June 24, 2024 2

@abbuw you can leverage other utilities to make your CPU cores busy with optimizing a folder, such as fd:

fd . --type file --extension ogg "/path/to/folder" -x optivorbis {} {.}_optimized.ogg

After that, you can verify that optimized files are valid and remove the original ones, then strip _optimized from filenames. Quick and dirty, take it or leave it 😄

from optivorbis.

murlakatamenka avatar murlakatamenka commented on June 24, 2024 2

Yes, GNU parallel is another alternative.

@abbuw didn't specify the platform he uses, so I've written about cross-platform fd only. parallel is via MSYS2 or WSL on Windows as I understand.

from optivorbis.

AlexTMjugador avatar AlexTMjugador commented on June 24, 2024

Hi! 👋

In-place optimization is a bit tricky for OptiVorbis. Its two-pass optimization techniques require the input file to be available while the output file is generated, so a temporary output file must be used and atomically moved to the original path after optimizations. Getting this done right across platforms requires attention to detail, so it was not in scope for the first public release.

On the dragging and dropping part, while I understand that it can be a significant UX improvement, at a technical level that gesture is just another way of passing command line parameters, and I'm unsure whether I want to change the CLI interface to accommodate that use case. For example, if two files are dragged and dropped, two paths are passed to the CLI, so what should OptiVorbis do: optimize the file referenced by the first path to the second path (the current behavior), or optimize both files in place? OptiVorbis does not know if the user dragged and dropped files or used a command-line prompt, so it's impossible to guess what the user wants from the paths alone.

Anyway, your suggestions are intriguing, and even if they do not make it to the application, I welcome user-contributed ways to make these operations easier! Thank you for your feedback 😄

from optivorbis.

AlexTMjugador avatar AlexTMjugador commented on June 24, 2024

Thanks for the tip, @murlakatamenka! I've used tools like parallel several times myself to execute commands in parallel across file sets, but I didn't think of it when I wrote that reply 😄

from optivorbis.

Related Issues (7)

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.