Skip to content

Commit

Permalink
Fixed alpha and prores saving.
Browse files Browse the repository at this point in the history
  • Loading branch information
ggarra13 committed Feb 24, 2024
1 parent a7d120d commit 4ba3beb
Show file tree
Hide file tree
Showing 7 changed files with 25 additions and 13 deletions.
2 changes: 2 additions & 0 deletions mrv2/docs/HISTORY.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ v1.0.6
multiple movie or image files.
- Made FFmpeg errors be reported to the console immediately.
- Fixed macOS VideoToolbox's hardware encoding not working when busy.
- Fixed Windows' presets not being read due to spaces in the installed
directory.


v1.0.5
Expand Down
9 changes: 6 additions & 3 deletions mrv2/lib/mrvFl/mrvSaveImage.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -288,11 +288,14 @@ namespace mrv
render->setOCIOOptions(view->getOCIOOptions());
render->setLUTOptions(view->lutOptions());
CHECK_GL;
// glClearColor(1.0, .0, .0, 1.0);
// glClear(GL_COLOR_BUFFER_BIT);
render->drawVideo(
{videoData},
{math::Box2i(0, 0, renderSize.w, renderSize.h)});
{math::Box2i(
0, 0, renderSize.w, renderSize.h)},
{timeline::ImageOptions()},
{timeline::DisplayOptions()},
timeline::CompareOptions(),
ui->uiView->getBackgroundOptions());
CHECK_GL;
render->end();
}
Expand Down
6 changes: 5 additions & 1 deletion mrv2/lib/mrvFl/mrvSaveMovie.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -585,7 +585,11 @@ namespace mrv
render->drawVideo(
{videoData},
{math::Box2i(
0, 0, renderSize.w, renderSize.h)});
0, 0, renderSize.w, renderSize.h)},
{timeline::ImageOptions()},
{timeline::DisplayOptions()},
timeline::CompareOptions(),
ui->uiView->getBackgroundOptions());
render->end();
}

Expand Down
2 changes: 1 addition & 1 deletion mrv2/lib/mrvFl/mrvSaveOptions.h
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ namespace mrv
std::string ffmpegPreset;
std::string ffmpegPixelFormat;
tl::ffmpeg::AudioCodec ffmpegAudioCodec = tl::ffmpeg::AudioCodec::AAC;
bool ffmpegOverride;
bool ffmpegOverride = false;
std::string ffmpegColorRange;
std::string ffmpegColorSpace;
std::string ffmpegColorPrimaries;
Expand Down
15 changes: 9 additions & 6 deletions mrv2/lib/mrvWidgets/mrvSaveMovieOptionsUI.fl
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,7 @@ settings->setValue("SaveMovie/Annoations", static_cast<int>(o->value()));}
}
}
Fl_Group VideoOptions {
label {Video Options} open selected
label {Video Options} open
xywh {34 111 390 188} box ROUNDED_FRAME color 56
} {
Fl_Choice Profile {
Expand All @@ -275,11 +275,8 @@ add_pixel_formats(o, v->PixelFormat);
const Fl_Menu_Item* item = o->mvalue();
if (!item) return;
auto settings = mrv::App::app->settings();
settings->setValue("SaveMovie/Profile", std::string(item->label()));} open
settings->setValue("SaveMovie/Profile", std::string(item->label()));} open selected
tooltip {FFMpeg's Profile settings.} xywh {170 131 170 29} down_box BORDER_BOX
code0 {add_profiles(o);}
code1 {add_presets(o, Preset);}
code2 {add_pixel_formats(o, PixelFormat);}
} {}
Fl_Choice Preset {
label Preset
Expand Down Expand Up @@ -346,7 +343,7 @@ v->hide();}
}
}
Fl_Window uiAdvancedSettings {
label {Advanced Settings} open
label {Advanced Settings}
xywh {720 371 411 310} type Double hotspot modal visible
} {
Fl_Check_Button Override {
Expand Down Expand Up @@ -557,6 +554,12 @@ if (audioOnly)
Annotations->deactivate();
VideoOptions->deactivate();
}
else
{
add_profiles(Profile);
add_presets(Profile, Preset);
add_pixel_formats(Profile, PixelFormat);
}
uiAdvancedSettings->hide();
uiMain->show();
while (uiMain->visible())
Expand Down
2 changes: 1 addition & 1 deletion mrv2/presets/prores_4444-good.pst
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@
vendor:apl0
qscale:11
quant_mat:hq
allow_sw:1
alpha_bits:16
2 changes: 1 addition & 1 deletion tlRender

0 comments on commit 4ba3beb

Please sign in to comment.