mirror of
https://github.com/ynput/ayon-core.git
synced 2025-12-24 12:54:40 +01:00
Added profiles to ExtractThumbnail
This commit is contained in:
parent
a2a5f54857
commit
2885ed1805
1 changed files with 48 additions and 27 deletions
|
|
@ -400,24 +400,28 @@ class ExtractThumbnailOIIODefaultsModel(BaseSettingsModel):
|
|||
)
|
||||
|
||||
|
||||
class ExtractThumbnailModel(BaseSettingsModel):
|
||||
_isGroup = True
|
||||
enabled: bool = SettingsField(True)
|
||||
class ExtractThumbnailProfileModel(BaseSettingsModel):
|
||||
product_types: list[str] = SettingsField(
|
||||
default_factory=list, title="Product types"
|
||||
)
|
||||
hosts: list[str] = SettingsField(default_factory=list, title="Host names")
|
||||
task_types: list[str] = SettingsField(
|
||||
default_factory=list, title="Task types", enum_resolver=task_types_enum
|
||||
)
|
||||
task_names: list[str] = SettingsField(
|
||||
default_factory=list, title="Task names"
|
||||
)
|
||||
product_names: list[str] = SettingsField(
|
||||
default_factory=list,
|
||||
title="Product names"
|
||||
default_factory=list, title="Product names"
|
||||
)
|
||||
integrate_thumbnail: bool = SettingsField(
|
||||
True,
|
||||
title="Integrate Thumbnail Representation"
|
||||
True, title="Integrate Thumbnail Representation"
|
||||
)
|
||||
target_size: ResizeModel = SettingsField(
|
||||
default_factory=ResizeModel,
|
||||
title="Target size"
|
||||
default_factory=ResizeModel, title="Target size"
|
||||
)
|
||||
background_color: ColorRGBA_uint8 = SettingsField(
|
||||
(0, 0, 0, 0.0),
|
||||
title="Background color"
|
||||
(0, 0, 0, 0.0), title="Background color"
|
||||
)
|
||||
duration_split: float = SettingsField(
|
||||
0.5,
|
||||
|
|
@ -434,6 +438,15 @@ class ExtractThumbnailModel(BaseSettingsModel):
|
|||
)
|
||||
|
||||
|
||||
class ExtractThumbnailModel(BaseSettingsModel):
|
||||
_isGroup = True
|
||||
enabled: bool = SettingsField(True)
|
||||
|
||||
profiles: list[ExtractThumbnailProfileModel] = SettingsField(
|
||||
default_factory=list, title="Profiles"
|
||||
)
|
||||
|
||||
|
||||
def _extract_oiio_transcoding_type():
|
||||
return [
|
||||
{"value": "colorspace", "label": "Use Colorspace"},
|
||||
|
|
@ -1458,22 +1471,30 @@ DEFAULT_PUBLISH_VALUES = {
|
|||
},
|
||||
"ExtractThumbnail": {
|
||||
"enabled": True,
|
||||
"product_names": [],
|
||||
"integrate_thumbnail": True,
|
||||
"target_size": {
|
||||
"type": "source"
|
||||
},
|
||||
"duration_split": 0.5,
|
||||
"oiiotool_defaults": {
|
||||
"type": "colorspace",
|
||||
"colorspace": "color_picking"
|
||||
},
|
||||
"ffmpeg_args": {
|
||||
"input": [
|
||||
"-apply_trc gamma22"
|
||||
],
|
||||
"output": []
|
||||
}
|
||||
"profiles": [
|
||||
{
|
||||
"product_types": [],
|
||||
"hosts": [],
|
||||
"task_types": [],
|
||||
"task_names": [],
|
||||
"product_names": [],
|
||||
"integrate_thumbnail": True,
|
||||
"target_size": {
|
||||
"type": "source"
|
||||
},
|
||||
"duration_split": 0.5,
|
||||
"oiiotool_defaults": {
|
||||
"type": "colorspace",
|
||||
"colorspace": "color_picking"
|
||||
},
|
||||
"ffmpeg_args": {
|
||||
"input": [
|
||||
"-apply_trc gamma22"
|
||||
],
|
||||
"output": []
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
"ExtractOIIOTranscode": {
|
||||
"enabled": True,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue