Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
19 commits
Select commit Hold shift + click to select a range
53a7ef4
First version to create dependencies for compilation
leighsmith Jun 25, 2026
f1788fb
Fix conan path, clean up FFMPEG_MINIMAL checking
leighsmith Jun 25, 2026
2eb581e
Added many more dependencies to be installed by apt-get
leighsmith Jun 25, 2026
09a54df
Added ffmpeg dev libraries
leighsmith Jun 26, 2026
1e88472
Added minizip for command, opencv and yaml-cpp dev libraries
leighsmith Jun 26, 2026
da7c4f9
Experiment with simple rename of ObservableValue for Observable for l…
leighsmith Jun 26, 2026
5f99814
Rename ObservableValue for Observable template
leighsmith Jun 26, 2026
deec0f7
Renamed to latest feather-tk, ValueObserver to Observer, CmdLineValue…
leighsmith Jun 26, 2026
69ffa6a
Renamed to latest feather-tk, ValueObserver to Observer, CmdLineValue…
leighsmith Jun 26, 2026
4c25505
Renamed CmdLineValueOption and CmdLineValueArg to CmdLineOption and C…
leighsmith Jun 26, 2026
cf141f6
Renamed CmdLineValueOption and CmdLineValueArg to CmdLineOption and C…
leighsmith Jun 26, 2026
976f0d0
Renamed CmdLineFlagOption to CmdLineFlag
leighsmith Jun 26, 2026
6b91bfb
Clean up declarations for changed feature-tk API
leighsmith Jun 26, 2026
592d2b3
Create a version of getExit() to replace the deprecated feather-tk AP…
leighsmith Jun 29, 2026
caf0fb9
Create a version of getExit() to replace the deprecated feather-tk AP…
leighsmith Jun 29, 2026
cf89278
Revamped for new Action::create() parameters, accepting a KeyShortcut…
leighsmith Jun 29, 2026
b41abb4
Corrected feather-tk declarations for updated API
leighsmith Jun 29, 2026
1d2614c
Bulk conversion of ::sizeHintEvent(const ftk::SizeHintEvent& event) t…
leighsmith Jun 30, 2026
146cf08
Removed older libminizip-dev which probably confuses CMake
leighsmith Jun 30, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
64 changes: 64 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
# -*- mode: sh -*-
# vi: set ft=bash :

FROM ubuntu:latest AS builder

WORKDIR /home/ubuntu

RUN apt-get update && apt-get install -y build-essential \
cmake \
g++ \
git \
minizip \
libminizip-ng-dev \
xorg-dev \
libglu1-mesa-dev \
mesa-common-dev \
mesa-utils \
curl \
pipx \
libjpeg-dev \
libtiff-dev \
libpng++-dev \
libimath-dev \
libopencv-dev \
ffmpeg \
libyaml-cpp-dev \
libavcodec-dev \
libavformat-dev \
libswscale-dev \
openimageio-tools \
libopenexr-dev \
libopenimageio-dev \
libopencolorio-dev \
libopentimelineio-dev

# Clone, compile and install feather-tk library
RUN mkdir feather-tk
RUN cd feather-tk; git clone https://github.com/grizzlypeak3d/feather-tk.git
RUN cd feather-tk; sh feather-tk/sbuild-linux.sh feather-tk
# TODO replace with cmake --target install
RUN tar -C feather-tk/install-Release -c -f - . | tar -C /usr/local -x -f -

# Add the pipx installation location:
ENV PATH=/root/.local/share/pipx/venvs/conan/bin:$PATH

# We need conan for openFX building.
RUN pipx ensurepath
RUN pipx install conan
RUN conan profile detect

# TODO Unable to get it because of github blocking automation.
# curl -O https://github.com/AcademySoftwareFoundation/openfx/releases/download/OFX_Release_1.5.1/openfx-linux-ubuntu-1.5.1.tar.gz
RUN git clone https://github.com/AcademySoftwareFoundation/openfx.git
# TODO this doesn't build on arm64 Linux currently, can't find the architecture.
RUN cd openfx; scripts/build-cmake.sh
# TODO need to find a better installation method, cmake --target install
RUN mkdir /usr/local/include/OpenFX
RUN tar -C openfx/include -c -f - . | tar -C /usr/local/include/OpenFX -x -f -

# RUN git clone https://github.com/OpenTimelineIO/toucan.git
# RUN git clone https://github.com/leighsmith/toucan.git
COPY . /home/ubuntu/toucan

# RUN sh toucan/sbuild-linux.sh
11 changes: 8 additions & 3 deletions bin/toucan-filmstrip/App.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@ namespace toucan
const std::shared_ptr<ftk::Context>& context,
std::vector<std::string>& argv)
{
_cmdLine.input = ftk::CmdLineValueArg<std::string>::create(
_cmdLine.input = ftk::CmdLineArg<std::string>::create(
"input",
"Input .otio file.");
_cmdLine.output = ftk::CmdLineValueArg<std::string>::create(
_cmdLine.output = ftk::CmdLineArg<std::string>::create(
"output",
"Output image file.");

Expand All @@ -44,7 +44,12 @@ namespace toucan
out->_init(context, argv);
return out;
}


int App::getExit() const
{
return 0; // TODO stub for now to replace deprecated API of feather-tk IApp.h.
}

void App::run()
{
const std::filesystem::path parentPath = std::filesystem::path(getExeName()).parent_path();
Expand Down
9 changes: 6 additions & 3 deletions bin/toucan-filmstrip/App.h
Original file line number Diff line number Diff line change
Expand Up @@ -30,13 +30,16 @@ namespace toucan
const std::shared_ptr<ftk::Context>&,
std::vector<std::string>&);

void run() override;
//! Get the exit code.
FTK_API int getExit() const;

void run();

private:
struct CmdLine
{
std::shared_ptr<ftk::CmdLineValueArg<std::string> > input;
std::shared_ptr<ftk::CmdLineValueArg<std::string> > output;
std::shared_ptr<ftk::CmdLineArg<std::string> > input;
std::shared_ptr<ftk::CmdLineArg<std::string> > output;
};
CmdLine _cmdLine;

Expand Down
25 changes: 15 additions & 10 deletions bin/toucan-render/App.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -47,10 +47,10 @@ namespace toucan
const std::shared_ptr<ftk::Context>& context,
std::vector<std::string>& argv)
{
_cmdLine.input = ftk::CmdLineValueArg<std::string>::create(
_cmdLine.input = ftk::CmdLineArg<std::string>::create(
"input",
"Input .otio file.");
_cmdLine.output = ftk::CmdLineValueArg<std::string>::create(
_cmdLine.output = ftk::CmdLineArg<std::string>::create(
"output",
"Output image or movie file. Use a dash ('-') to write raw frames or y4m to stdout.");

Expand All @@ -64,37 +64,37 @@ namespace toucan
{
y4mList.push_back(spec.first);
}
_cmdLine.videoCodec = ftk::CmdLineValueOption<std::string>::create(
_cmdLine.videoCodec = ftk::CmdLineOption<std::string>::create(
std::vector<std::string>{ "-vcodec" },
"Set the video codec.",
"",
"MJPEG",
ftk::join(ffmpeg::getVideoCodecStrings(), ", "));
_cmdLine.printStart = ftk::CmdLineFlagOption::create(
_cmdLine.printStart = ftk::CmdLineFlag::create(
std::vector<std::string>{ "-print_start" },
"Print the timeline start time and exit.");
_cmdLine.printDuration = ftk::CmdLineFlagOption::create(
_cmdLine.printDuration = ftk::CmdLineFlag::create(
std::vector<std::string>{ "-print_duration" },
"Print the timeline duration and exit.");
_cmdLine.printRate = ftk::CmdLineFlagOption::create(
_cmdLine.printRate = ftk::CmdLineFlag::create(
std::vector<std::string>{ "-print_rate" },
"Print the timeline frame rate and exit.");
_cmdLine.printSize = ftk::CmdLineFlagOption::create(
_cmdLine.printSize = ftk::CmdLineFlag::create(
std::vector<std::string>{ "-print_size" },
"Print the timeline image size.");
_cmdLine.raw = ftk::CmdLineValueOption<std::string>::create(
_cmdLine.raw = ftk::CmdLineOption<std::string>::create(
std::vector<std::string>{ "-raw" },
"Raw pixel format to send to stdout.",
"",
std::optional<std::string>(),
ftk::join(rawList, ", "));
_cmdLine.y4m = ftk::CmdLineValueOption<std::string>::create(
_cmdLine.y4m = ftk::CmdLineOption<std::string>::create(
std::vector<std::string>{ "-y4m" },
"y4m format to send to stdout.",
"",
std::optional<std::string>(),
ftk::join(y4mList, ", "));
_cmdLine.verbose = ftk::CmdLineFlagOption::create(
_cmdLine.verbose = ftk::CmdLineFlag::create(
std::vector<std::string>{ "-v" },
"Print verbose output.");

Expand Down Expand Up @@ -149,6 +149,11 @@ namespace toucan
return out;
}

int App::getExit() const
{
return 0; // TODO stub for now to replace deprecated API of feather-tk IApp.h.
}

void App::run()
{
const std::filesystem::path parentPath = std::filesystem::path(getExeName()).parent_path();
Expand Down
25 changes: 14 additions & 11 deletions bin/toucan-render/App.h
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,10 @@ namespace toucan
const std::shared_ptr<ftk::Context>&,
std::vector<std::string>&);

void run() override;
//! Get the exit code.
FTK_API int getExit() const;

void run();

private:
void _writeRawFrame(const OIIO::ImageBuf&);
Expand All @@ -45,18 +48,18 @@ namespace toucan

struct CmdLine
{
std::shared_ptr<ftk::CmdLineValueArg<std::string> > input;
std::shared_ptr<ftk::CmdLineValueArg<std::string> > output;
std::shared_ptr<ftk::CmdLineArg<std::string> > input;
std::shared_ptr<ftk::CmdLineArg<std::string> > output;
bool outputRaw = false;

std::shared_ptr<ftk::CmdLineValueOption<std::string> > videoCodec;
std::shared_ptr<ftk::CmdLineFlagOption> printStart;
std::shared_ptr<ftk::CmdLineFlagOption> printDuration;
std::shared_ptr<ftk::CmdLineFlagOption> printRate;
std::shared_ptr<ftk::CmdLineFlagOption> printSize;
std::shared_ptr<ftk::CmdLineValueOption<std::string> > raw;
std::shared_ptr<ftk::CmdLineValueOption<std::string> > y4m;
std::shared_ptr<ftk::CmdLineFlagOption> verbose;
std::shared_ptr<ftk::CmdLineOption<std::string> > videoCodec;
std::shared_ptr<ftk::CmdLineFlag> printStart;
std::shared_ptr<ftk::CmdLineFlag> printDuration;
std::shared_ptr<ftk::CmdLineFlag> printRate;
std::shared_ptr<ftk::CmdLineFlag> printSize;
std::shared_ptr<ftk::CmdLineOption<std::string> > raw;
std::shared_ptr<ftk::CmdLineOption<std::string> > y4m;
std::shared_ptr<ftk::CmdLineFlag> verbose;
};
CmdLine _cmdLine;

Expand Down
4 changes: 2 additions & 2 deletions lib/toucanView/App.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ namespace toucan
const std::shared_ptr<ftk::Context>& context,
std::vector<std::string>& argv)
{
_input = ftk::CmdLineValueArg<std::string>::create(
_input = ftk::CmdLineArg<std::string>::create(
"input",
"Input timeline.",
true);
Expand Down Expand Up @@ -56,7 +56,7 @@ namespace toucan
std::dynamic_pointer_cast<App>(shared_from_this()),
"toucan-view",
ftk::Size2I(1920, 1080));
addWindow(_window);
_addWindow(_window);
_window->show();

if (_input->hasValue())
Expand Down
2 changes: 1 addition & 1 deletion lib/toucanView/App.h
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ namespace toucan
void open(const std::filesystem::path&);

private:
std::shared_ptr<ftk::CmdLineValueArg<std::string> > _input;
std::shared_ptr<ftk::CmdLineArg<std::string> > _input;
std::shared_ptr<ftk::Settings> _settings;
std::shared_ptr<TimeUnitsModel> _timeUnitsModel;
std::shared_ptr<ImageEffectHost> _host;
Expand Down
7 changes: 3 additions & 4 deletions lib/toucanView/BackgroundTool.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ namespace toucan
}
});

_optionsObserver = ftk::ValueObserver<GlobalViewOptions>::create(
_optionsObserver = ftk::Observer<GlobalViewOptions>::create(
_model->observeOptions(),
[this](const GlobalViewOptions& value)
{
Expand Down Expand Up @@ -125,10 +125,9 @@ namespace toucan
_scrollWidget->setGeometry(value);
}

void BackgroundTool::sizeHintEvent(const ftk::SizeHintEvent& event)
Size2I BackgroundTool::getSizeHint() const
{
IToolWidget::sizeHintEvent(event);
_setSizeHint(_scrollWidget->getSizeHint());
return _scrollWidget->getSizeHint();
}

void BackgroundTool::_widgetUpdate()
Expand Down
4 changes: 2 additions & 2 deletions lib/toucanView/BackgroundTool.h
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ namespace toucan
const std::shared_ptr<IWidget>& parent = nullptr);

void setGeometry(const ftk::Box2I&) override;
void sizeHintEvent(const ftk::SizeHintEvent&) override;
Size2I getSizeHint() const override;

private:
void _widgetUpdate();
Expand All @@ -52,7 +52,7 @@ namespace toucan
std::shared_ptr<ftk::ColorWidget> _checkersColor1Widget;
std::shared_ptr<ftk::IntEditSlider> _checkersSizeSlider;

std::shared_ptr<ftk::ValueObserver<GlobalViewOptions> > _optionsObserver;
std::shared_ptr<ftk::Observer<GlobalViewOptions> > _optionsObserver;
};
}

24 changes: 9 additions & 15 deletions lib/toucanView/CompareMenu.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,7 @@ namespace toucan

_actions["Compare/A"] = ftk::Action::create(
"A",
ftk::Key::A,
static_cast<int>(ftk::KeyModifier::Shift),
ftk::KeyShortcut(ftk::Key::A, ftk::KeyModifier::Shift),
[this](bool)
{
CompareOptions options = _filesModel->getCompareOptions();
Expand All @@ -36,8 +35,7 @@ namespace toucan

_actions["Compare/B"] = ftk::Action::create(
"B",
ftk::Key::B,
static_cast<int>(ftk::KeyModifier::Shift),
ftk::KeyShortcut(ftk::Key::B, ftk::KeyModifier::Shift),
[this](bool)
{
CompareOptions options = _filesModel->getCompareOptions();
Expand All @@ -48,8 +46,7 @@ namespace toucan

_actions["Compare/Split"] = ftk::Action::create(
"Split",
ftk::Key::S,
static_cast<int>(ftk::KeyModifier::Shift),
ftk::KeyShortcut(ftk::Key::S, ftk::KeyModifier::Shift),
[this](bool)
{
CompareOptions options = _filesModel->getCompareOptions();
Expand All @@ -60,8 +57,7 @@ namespace toucan

_actions["Compare/Overlay"] = ftk::Action::create(
"Overlay",
ftk::Key::E,
static_cast<int>(ftk::KeyModifier::Shift),
ftk::KeyShortcut(ftk::Key::E, ftk::KeyModifier::Shift),
[this](bool)
{
CompareOptions options = _filesModel->getCompareOptions();
Expand All @@ -72,8 +68,7 @@ namespace toucan

_actions["Compare/Horizontal"] = ftk::Action::create(
"Horizontal",
ftk::Key::H,
static_cast<int>(ftk::KeyModifier::Shift),
ftk::KeyShortcut(ftk::Key::H, ftk::KeyModifier::Shift),
[this](bool)
{
CompareOptions options = _filesModel->getCompareOptions();
Expand All @@ -84,8 +79,7 @@ namespace toucan

_actions["Compare/Vertical"] = ftk::Action::create(
"Vertical",
ftk::Key::V,
static_cast<int>(ftk::KeyModifier::Shift),
ftk::KeyShortcut(ftk::Key::V, ftk::KeyModifier::Shift),
[this](bool)
{
CompareOptions options = _filesModel->getCompareOptions();
Expand All @@ -94,7 +88,7 @@ namespace toucan
});
addAction(_actions["Compare/Vertical"]);

_modeObserver = ftk::ValueObserver<CompareOptions>::create(
_modeObserver = ftk::Observer<CompareOptions>::create(
app->getFilesModel()->observeCompareOptions(),
[this](const CompareOptions& value)
{
Expand Down Expand Up @@ -126,15 +120,15 @@ namespace toucan
}
});

_fileObserver = ftk::ValueObserver<std::shared_ptr<File> >::create(
_fileObserver = ftk::Observer<std::shared_ptr<File> >::create(
app->getFilesModel()->observeCurrent(),
[this](const std::shared_ptr<File>& file)
{
_file = file;
_menuUpdate();
});

_bIndexObserver = ftk::ValueObserver<int>::create(
_bIndexObserver = ftk::Observer<int>::create(
_filesModel->observeBIndex(),
[this](int index)
{
Expand Down
6 changes: 3 additions & 3 deletions lib/toucanView/CompareMenu.h
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@ namespace toucan
std::vector<std::shared_ptr<ftk::Action> > _bFileActions;

std::shared_ptr<ftk::ListObserver<std::shared_ptr<File> > > _filesObserver;
std::shared_ptr<ftk::ValueObserver<std::shared_ptr<File> > > _fileObserver;
std::shared_ptr<ftk::ValueObserver<int> > _bIndexObserver;
std::shared_ptr<ftk::ValueObserver<CompareOptions> > _modeObserver;
std::shared_ptr<ftk::Observer<std::shared_ptr<File> > > _fileObserver;
std::shared_ptr<ftk::Observer<int> > _bIndexObserver;
std::shared_ptr<ftk::Observer<CompareOptions> > _modeObserver;
};
}
Loading