I implemented second way: FileDialog stores selected filter index in preferences, and Importer retrieves this index and uses it to guess first import plug-in to try. Implementing this requires a few changes, some of them may involve cumbersome passing of additional argument through several functions from ShowOpenDialog to Importer. Make Importer aware of the file filter user choose in FileDialog, and assume that when user chooses "FFmpeg-compatible file" filter, he (user) wants to import files via FFmpeg, and by choosing "MP3 files" user suggests Audacity to use libmp3lame.At the moment FFmpeg is always registered last. When FFmpeg import plug-in is registered before all others, it would handle importing of any file without letting other plug-ins even try. By using this preference user could adjust the order in which plug-ins are being registered in Audacity. Add new preference - plug-in loading order.In some cases user may wish to use FFmpeg to import files however. FFmpeg also cannot (at the time of writing) import meta-data (tags) from raw FLAC files. Using built-in Audacity import/export modules is better because they support various sample formats, while FFmpeg supports only 16-bit integer samples. It means that static build is not very advantageous now, and should not be used unless there is a specific reason to do so.įFmpeg is able to import and export FLAC, OGG Vorbis, MP3, MP2 and various uncompressed wave files, however Audacity already possesses all necessary capabilities to work with these formats (except MP3 - exporting requires separate plug-in). Because of that it is possible to load both static and shared libraries regardless of their location, as long as all relevant shared libraries are either in one directory, or in the PATH (before there was a requirement that shared libraries had to be either in PATH or in Audacity directory). Also, now Audacity will modify application-wide environment variable PATH to include the directory where located library resides. Somewhere along the way the FFmpegLibs class was modified to support loading both shared and static libraries, and library locating dialog was redesigned and put into Preferences. Because all shared libraries should be in PATH, it's not useful to ask user for libraries' location when shared build is used, while with static build it may be necessary. When using static FFmpeg, Audacity only loads one library and imports everything from it. My guess is that Linux users would prefer shared FFmpeg, since they have superior package managing system, while on Windows it's easier to drop static FFmpeg build into Audacity and forget about packages.įrom Audacity's point of view there's only one difference: when using shared FFmpeg, Audacity has to load each function from respective library, and each library has to be mapped into Audacity process memory by separate wxDynamicLibrary object. Static build is usually stored somewhere within application's directory as some kind of plug-in. This is also necessary because libraries depend on each other. ![]() Valid system-wide FFmpeg package is usually shared, and resides somewhere in PATH, so any application is able to load functions from any of these libraries. Shared build results in a few libraries (and these libraries may depend on other non-FFmpeg libraries), each library exports different functions. Static build results in one big library, that contains all functions from FFmpeg package. ![]() It's not yet clear which build of FFmpeg will be used - static or shared. This allows FFmpeg to be optional (Audacity will run without FFmpeg) and it could be distributed separately (removes licensing issues). Note that details of the documentation or of the project implementation itself may change over time.Īs a design decision, FFmpeg libraries are being linked dynamically and loaded at run time. User documentation was produced by the student and has been incorporated into appropriate pages in the Audacity Manual. While FFmpeg also has other uses, this is outside the scope of this project. In Audacity FFmpeg will be used to import and export audio data.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |