[PR #12561] [MERGED] Use enums for encoding options #13253

Closed
opened 2026-02-07 07:09:43 +03:00 by OVERLORD · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/jellyfin/jellyfin/pull/12561
Author: @Shadowghost
Created: 9/1/2024
Status: Merged
Merged: 9/9/2024
Merged by: @crobibero

Base: masterHead: encoding-options-enums


📝 Commits (5)

📊 Changes

20 files changed (+883 additions, -475 deletions)

View changed files

📝 Jellyfin.Api/Controllers/DynamicHlsController.cs (+2 -2)
📝 Jellyfin.Api/Controllers/VideosController.cs (+1 -1)
📝 Jellyfin.Server/Migrations/MigrationRunner.cs (+2 -1)
📝 Jellyfin.Server/Migrations/PreStartupRoutines/CreateNetworkConfiguration.cs (+0 -1)
Jellyfin.Server/Migrations/PreStartupRoutines/MigrateEncodingOptions.cs (+245 -0)
📝 Jellyfin.Server/Migrations/PreStartupRoutines/MigrateMusicBrainzTimeout.cs (+5 -5)
📝 Jellyfin.Server/Migrations/PreStartupRoutines/MigrateNetworkConfiguration.cs (+44 -41)
📝 MediaBrowser.Controller/MediaEncoding/EncodingHelper.cs (+259 -335)
📝 MediaBrowser.MediaEncoding/Encoder/MediaEncoder.cs (+9 -8)
📝 MediaBrowser.MediaEncoding/Transcoding/TranscodeManager.cs (+1 -6)
📝 MediaBrowser.Model/Configuration/EncodingOptions.cs (+14 -12)
MediaBrowser.Model/Entities/DeinterlaceMethod.cs (+19 -0)
MediaBrowser.Model/Entities/EncoderPreset.cs (+64 -0)
MediaBrowser.Model/Entities/HardwareAccelerationType.cs (+49 -0)
MediaBrowser.Model/Entities/TonemappingAlgorithm.cs (+49 -0)
MediaBrowser.Model/Entities/TonemappingMode.cs (+34 -0)
MediaBrowser.Model/Entities/TonemappingRange.cs (+24 -0)
MediaBrowser.Model/Session/HardwareEncodingType.cs (+0 -43)
📝 MediaBrowser.Model/Session/TranscodingInfo.cs (+60 -18)
📝 src/Jellyfin.MediaEncoding.Hls/Playlist/DynamicHlsPlaylistGenerator.cs (+2 -2)

📄 Description

Add enums for:

  • DeinterlaceMethod
  • EncoderPreset
  • HardwareAccelerationType
  • TonemappingAlgorithm
  • TonemappingMode
  • TonemappingRange

A migration for the existing config was also added for completeness' sake. Since the string values are the same, it should not be necessary.

I also made sure they are backwards compatible with our current values by enforcing lowercase.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/jellyfin/jellyfin/pull/12561 **Author:** [@Shadowghost](https://github.com/Shadowghost) **Created:** 9/1/2024 **Status:** ✅ Merged **Merged:** 9/9/2024 **Merged by:** [@crobibero](https://github.com/crobibero) **Base:** `master` ← **Head:** `encoding-options-enums` --- ### 📝 Commits (5) - [`ae56cef`](https://github.com/jellyfin/jellyfin/commit/ae56cefe89b35874eee5246d6d22e580242bbe4d) Use enums for encoding options - [`6f8adf8`](https://github.com/jellyfin/jellyfin/commit/6f8adf817e0de503d1e6afdcdadd970e0d280109) Fixup - [`6fa7829`](https://github.com/jellyfin/jellyfin/commit/6fa78290ffe3343f1a6bc87d87fa8120cda81129) Fix formatting - [`23f0dda`](https://github.com/jellyfin/jellyfin/commit/23f0ddaeb746e84a0b9e61538c1aecdfddd515e3) Fixup - [`79f0acc`](https://github.com/jellyfin/jellyfin/commit/79f0acce276098c42a89038f136ec18af1fcdc91) Fix typo ### 📊 Changes **20 files changed** (+883 additions, -475 deletions) <details> <summary>View changed files</summary> 📝 `Jellyfin.Api/Controllers/DynamicHlsController.cs` (+2 -2) 📝 `Jellyfin.Api/Controllers/VideosController.cs` (+1 -1) 📝 `Jellyfin.Server/Migrations/MigrationRunner.cs` (+2 -1) 📝 `Jellyfin.Server/Migrations/PreStartupRoutines/CreateNetworkConfiguration.cs` (+0 -1) ➕ `Jellyfin.Server/Migrations/PreStartupRoutines/MigrateEncodingOptions.cs` (+245 -0) 📝 `Jellyfin.Server/Migrations/PreStartupRoutines/MigrateMusicBrainzTimeout.cs` (+5 -5) 📝 `Jellyfin.Server/Migrations/PreStartupRoutines/MigrateNetworkConfiguration.cs` (+44 -41) 📝 `MediaBrowser.Controller/MediaEncoding/EncodingHelper.cs` (+259 -335) 📝 `MediaBrowser.MediaEncoding/Encoder/MediaEncoder.cs` (+9 -8) 📝 `MediaBrowser.MediaEncoding/Transcoding/TranscodeManager.cs` (+1 -6) 📝 `MediaBrowser.Model/Configuration/EncodingOptions.cs` (+14 -12) ➕ `MediaBrowser.Model/Entities/DeinterlaceMethod.cs` (+19 -0) ➕ `MediaBrowser.Model/Entities/EncoderPreset.cs` (+64 -0) ➕ `MediaBrowser.Model/Entities/HardwareAccelerationType.cs` (+49 -0) ➕ `MediaBrowser.Model/Entities/TonemappingAlgorithm.cs` (+49 -0) ➕ `MediaBrowser.Model/Entities/TonemappingMode.cs` (+34 -0) ➕ `MediaBrowser.Model/Entities/TonemappingRange.cs` (+24 -0) ➖ `MediaBrowser.Model/Session/HardwareEncodingType.cs` (+0 -43) 📝 `MediaBrowser.Model/Session/TranscodingInfo.cs` (+60 -18) 📝 `src/Jellyfin.MediaEncoding.Hls/Playlist/DynamicHlsPlaylistGenerator.cs` (+2 -2) </details> ### 📄 Description Add enums for: * DeinterlaceMethod * EncoderPreset * HardwareAccelerationType * TonemappingAlgorithm * TonemappingMode * TonemappingRange A migration for the existing config was also added for completeness' sake. Since the string values are the same, it should not be necessary. I also made sure they are backwards compatible with our current values by enforcing lowercase. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
OVERLORD added the pull-request label 2026-02-07 07:09:43 +03:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/jellyfin#13253