-
Notifications
You must be signed in to change notification settings - Fork 591
Improved Profiles (400+ Export Profiles, New Profile UI, and more) #5116
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…er 400 unique profile resolution + frame rates. These include the ATSC standards, Sony D1, CIF, Blu-ray, DVD, DVB, HDV, VCD/SVCD, Facebook/Instagram, NTSC, PAL, and VGA.
…orphic sizes, and initial checkin of manage.py script to help parse, test, and update these formats for the future.
…generate valid export presets from our JSON definitions
…s and find equivalent new preset
…ameWithDesc() function - standardizing profile names
… for storing and processing
…e Key() from libopenshot::Profile class. Re-generating all profiles.
…so, adding initial Presets update logic into manage.py script.
…f Anamorphic formats (and adding Note automatically), and better generation of profiles with a more uniform description.
…ngle definition, and regenerate affected profiles
…e.py script, to move NTSC/PAL/SD/HD to the front of the description, and Anamorphic to the end of the description.
…le names, and correctly order FHD, UHD, and other labels to the front of the description
… ratio, and fixed vertical resolutiosn to use the original width (i.e. 720p Vertical instead of 1280p Vertical), and regenerating all profiles
…esolutions, and regenerating affected profiles
…archable. Now requires user to click "Ok" button to prevent accidental changes to Profile.
… TimelineSync object (where the JSON is applied or loaded in libopenshot) - Add playback caching setting when Profile dialog changes profile in accept() method
- separate Profile UI from default project id, and allow it to be more generic - Allow profile to initially select any profile by description or Key() - Correctly apply the profile of a loaded project, and fallback to a default if not found
…ll as 0 sample rate and 0 channels (indicating missing video or audio tracks) - Allow up to 384000 sample rate (and 0) - Update GIF preset to remove audio info - Update MP3 preset to remove video info - Improve manage.py profile script, to auto-generate our *.rst profile documenation (list of presets and profiles) - Update profiles documentation (presets list and profiles list)
- Removing unused variables - Removing unreachable code - Wrapping some long code lines - Removing unneeded elif
- Replaced minidomxml with defusedxml (safer) - Removed unneeded else's - Removed unneeded overloaded method - Removed unused key in dict loop - Fixed some long lines that needed to wrap
- Avoid using built-in variable - Removing unneeded elif - Reduce complexity of Exception string
… and profiles.rst file - to help demonstrate how SAR is applied to the final display resolution
…d - related to our new Profiles UI. Also tweaking the column widths of the generated profile list syntax.
…ving these profile files
…de the ":" character, since Windows has issues with this character in file paths.
…er FFmpeg versions
- Fixing bug when rescaling FPS to a new FPS, to prevent undo/redo history from being erased
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This is a big PR, with a new approach to managing Export Profiles. Since most of OpenShot's profiles were inherited from our old 1.x code base, and not personally sourced by myself, I thought it would be a fun exercise to research common video sizes and frame rates, and compile a comprehensive list of useful ones. And since this type of work can be easy to make mistakes, I based all my work around the concept of a simple
manage.py
script, which could read in simple JSON definitions, and output a variety of things, including verifying my math, and verifying we have no duplicates, etc...New Profile UI:
Instead of a long dropdown which is difficult to search (especially with 400+ profiles), we now have a filterable / searchable UI for selecting a new Project Profile. These profiles affect the video size (width, height), frame rate, display aspect ratio, sample aspect ratio (i.e. anamorphic), and include some common phrases often associated with it, for example 1920x1080 is FHD, etc... You can simply double click on the profile you want, or click the "Okay" button after making a selection.
New Export UI:
Similarly, when exporting your project, you can click the small "Profile" icon next to the drop down, and it will display the same Profile UI displayed above, which is filterable and searchable.
Backwards Compatibility:
We continue to support our Legacy profiles (now found in
src/profiles/legacy/
), however OpenShot will now automatically switch you to a new matching profile when you open existing projects. These are basically identical matches (perhaps with a modified name), so it should not cause any issues, but I wanted to mention it here.Profile manage.py script:
The JSON definition files following the following syntax:
The
manage.py "generate"
command will parse all these JSON definitions, validate them, de-dupe them, try and normalize the text description formatting and capitalization, and will output hundreds of unique profile files (same format as before, and the format we load at runtime - compatible with previous versions of OpenShot):Example profile generated: 01920x1080p2398_16:09