Commit Graph
122 Commits
Author SHA1 Message Date
Mike-Solar a7ddc0f114 audio: master-clock playback timing, output clock compensation, buffer config, interpolated speed
- playback timer uses the audio output device as its master clock: the
  PortAudio callback counts consumed frames (including underrun
  zero-fill) so video cannot drift away from what is heard; wall clock
  remains as fallback when no clocked output is running
- output clock compensates for device output latency; new Preferences >
  Audio buffer size setting (0 = auto)
- SampleBuffer::speed() now uses linear interpolation instead of
  nearest-neighbor sampling
- regression tests: audio-clock driven timer (fwd/rev/speed), wall
  clock fallback, interpolation correctness
2026-07-19 21:44:34 +08:00
Mike-Solar 0c02ff0d77 proxy: isolate proxies from export renders and improve proxy workflow
- FootageJob::should_use_proxy() centralizes the proxy decision; worker
  pre-decode now honors the render mode so exports always decode the
  original media (previously every frame was pre-decoded from proxies)
- global Tools > Use Proxy Media toggle with footage invalidation
- ffmpeg -progress parsing for real percentage feedback while generating
- divider mode (1/2, 1/4, 1/8 of source resolution) with UI, proxy
  filename tags and per-footage persistence (pdivider)
- Media Offline warning slat rendered for missing footage
- regression tests: export isolation, relink invalidation, offline slat,
  progress parsing, divider arguments
2026-07-19 21:43:58 +08:00
Mike-Solar bb40b4923e style: unify identifier naming per updated conventions
Automated with clang-tidy readability-identifier-naming (config added to
.clang-tidy) plus scripted passes, per the updated rules now documented
in CONTRIBUTING.md:

- types (class/struct/enum/alias/template params): PascalCase
- functions, variables, members: snake_case (incl. rational -> Rational)
- private/protected members: trailing underscore; static member
  variables likewise (instance_, available_themes_)
- constants and enum values: snake_case (kLinear -> k_linear,
  F32P -> f32p); ALL_CAPS reserved for macros
- macros: OAK_ prefix (OLIVE_ADD_TEST/OLIVE_ASSERT/OLIVE_CONFIG ->
  OAK_ADD_TEST/OAK_ASSERT/OAK_CONFIG, GL_PREAMBLE -> OAK_GL_PREAMBLE,
  include guards -> OAK_*)
- file names: all lowercase (Current/Plugin/OliveHost/OliveClip/
  OlivePluginInstance -> current/plugin/olivehost/oliveclip/
  oliveplugininstance)
- getters share the member name sans underscore, setters set_foo()
- Qt and third-party (OpenFX) virtual overrides and framework callbacks
  keep their original names (exempt in .clang-tidy)

Manual follow-ups required where automation could not reach:
- string-based QMetaObject/SIGNAL/SLOT references updated to renamed
  methods (AddTask, CreatedFile, DeleteSpecificFile, moveSelectionUp, ...)
- macro bodies referencing renamed methods (OLIVE_CONFIG,
  NODE_DEFAULT_DESTRUCTOR, MANAGEDDISPLAYWIDGET_*)
- self-shadowing locals renamed where signals/methods became same-named
  (size_changed, worker_count, selected_items, import param, filters)
- third_party OFX member/namespace usages restored (OFX::Host::*,
  _created, _clipPrefsDirty, createInstance, clearPersistentMessage)
- STL protocol aliases restored (const_iterator) with .clang-tidy
  ignore rules; qHash overloads restored

Full build and test suite pass: ctest 4/4, ~1960 gtest cases green.
2026-07-19 16:10:54 +08:00
Mike-Solar 547c2480e0 color: global LUT library, LUT error reporting, clamp + display fixes
- Add a global LUT library: user-configurable directories (new
  Preferences > LUT tab) scanned recursively for .cube/.3dl files; LUT
  node file pickers offer the library dirs as sidebar shortcuts via a
  'lut_library' input property handled by the param view bridge
- OCIOLutNode no longer fails silently: missing files, unsupported
  extensions and OCIO load errors are recorded in last_error() and
  surfaced in the status bar (input still passes through for rendering
  safety)
- ColorDialog: re-enable the display -> reference conversion using
  ColorProcessor::kInverse with a validity guard, and re-enable the
  Display tab in ColorValuesWidget; covered by a round-trip regression
  test proving the old OCIO inverse crash no longer occurs
- OCIOGradingTransformLinearNode: enforce the OCIO clampWhite >
  clampBlack invariant per frame in Value() so keyframed/connected
  values cannot produce invalid grading transforms, and constrain the
  white clamp UI minimum whenever the black clamp is static
- Regression tests for LUT extension checks, direction switching, node
  error reporting, LUT library scanning, display inverse round-trip and
  clamp enforcement
2026-07-16 22:53:33 +08:00
Mike-Solar 6aaf37e2e5 proxy: per-footage presets, audio in proxies, configurable ffmpeg path
- Footage can store custom proxy parameters (width/height/crf/preset/
  extension/audio) that override the global settings; they are
  serialized with the project and used by every generation entry point
  via Footage::GetEffectiveProxyParams()
- Proxies now include the source audio streams (AAC) unless disabled;
  the proxy filename records the audio flag and offline audio rendering
  decodes from the proxy when present
- ProxyTask resolves ffmpeg from the new FFmpegPath config key first,
  then PATH, then common install locations (e.g. Homebrew on macOS),
  instead of relying on PATH only; the error message points at the
  preferences when no executable is found
- ProxyTask::BuildArguments() is extracted for testability
- Add ProxyIncludeAudio and FFmpegPath config defaults
- Add regression tests for the filename audio marker, config-backed
  params, ffmpeg resolution, argument building, and custom-param
  persistence
2026-07-16 22:31:37 +08:00
Mike-Solar 3a3ead6fc0 app: route all FFmpeg access through the ffmpeg_bridge C API
Replace every direct FFmpeg call in the editor and the render worker
with the pure C ffmpeg_bridge API, wrapped in thin C++ adapters that
preserve the original interfaces:

- avframeptr.h: olive::AVFrame adapter around FBFrame handles
- ffmpegutils: format conversion helpers on FB_* constants; the int
  overload is renamed GetCompatibleBridgePixelFormat to avoid a silent
  overload-resolution trap with the PixelFormat enum
- ffmpegdecoder/ffmpegencoder: rewritten as handle-based adapters over
  FBDecoder/FBProbe/FBEncoder/FBScaler/FBResampler
- audioprocessor: FBAudioGraph push/pull adapter
- pluginrenderer/OliveClip: sws/pixdesc usage converted to FBScaler and
  fb_pix_fmt_* queries
- AudioParams/channel layouts are plain uint64_t masks everywhere

Build integration: the root project no longer links FFMPEG directly;
only ffmpeg_bridge does. Binaries resolve the bridge library at runtime
via @loader_path inside the macOS app bundle (copied there post-build)
and via $ORIGIN/../ffmpeg_bridge/bin on Linux; on Windows the DLL is
installed next to the executables, so packages on all three platforms
ship the bridge library.

ffmpeg_bridge gains the extra API the adapters need:
fb_frame_make_writable, fb_decoder_get_format_duration,
fb_resampler_convert_frame, FB_PIX_FMT_YUV440P, SRT validation in
fb_probe_read_subtitle_stream, packed/planar fixes in
fb_encoder_write_audio, and a component-size fix in
fb_pix_fmt_component_size.
2026-07-15 23:00:06 +08:00
Mike-Solar e5eeaddf2f format: reformatting files 2026-07-13 15:30:43 +08:00
Mike-Solar f0119a910c Enable video auto-cache by default
- Default ViewerOutput::autocache_input_video_ to true so new sequences
  and viewer outputs use the frame cache without requiring the user to
  manually enable Auto-Cache.
- Update the DefaultSequenceAutoCache2 config default to true for
  consistency.
2026-07-13 10:19:30 +08:00
Mike-Solar cf32fcfee1 Add configurable proxy settings and a menu entry
- Extend ProxyManager::ProxyParams with crf and preset, and update
  ProxyTask/ProxyParamsEqual to use them.
- Add global config keys ProxyWidth, ProxyHeight, ProxyCRF, ProxyPreset.
- Add a Proxy Settings group to Preferences -> Disk with width/height/CRF/preset
  controls.
- Read proxy settings from config when generating proxies from the timeline.
- Add Tools -> Proxy Settings... menu entry that opens Preferences on the Disk tab.
- Add ConfigDialogBase::SetCurrentTab() so PreferencesDialog can start on a
  specific tab.
2026-07-13 10:19:30 +08:00
Mike-Solar f6211f97a5 Fix render worker reuse and stabilize out-of-process video rendering 2026-07-13 10:19:30 +08:00
Mike-Solar 341283b1cd Add graphics backend selection 2026-07-13 10:19:29 +08:00
Mike-Solar 98c884c381 Wire render worker pool into render manager 2026-06-04 16:23:36 +08:00
Mike-Solar 599c876d03 全链路强制F32 2026-05-14 01:51:14 +08:00
Mike-Solar bfb1b2fce4 update copyright back 2026-01-16 21:22:05 +08:00
Mike-Solar b8669f6a11 Change project name; 2026-01-05 16:22:26 +08:00
Mike-Solar 86e82b13e2 remove unused includes 2026-01-05 14:24:28 +08:00
Mike Solar 6fdfd03ffd update: update copyright 2025-08-05 17:12:49 +08:00
Mike Solar 74f73ab3be change: change code style to Linux style except indent. 2025-08-03 03:09:40 +08:00
itsmattkc c1c6893713 various: moved more to core lib 2023-01-19 16:01:31 -08:00
itsmattkc dd9c52ab59 start moving core frameworks to external libraries 2023-01-19 09:51:47 -08:00
itsmattkc 55d51a1ee5 config: default to rectified waveforms on 2022-12-08 11:25:31 -08:00
itsmattkc 1c4149a0fd preferences: add option to use glFinish
i hate opengl i hate opengl i hate opengl i hate opengl i hate opengl i hate opengl i hate opengl i hate opengl i hate opengl i hate opengl i hate opengl i hate opengl i hate opengl i hate opengl
2022-11-05 12:49:30 -07:00
itsmattkc 3978a8501a timeline: implement select to seek and seek to select 2022-10-23 22:28:35 -07:00
itsmattkc 84fa33e510 config: default to thumbnail on in point only 2022-09-08 20:28:48 -07:00
itsmattkc 571be3d28d timeline: added thumbnail modes that affect how much is rendered 2022-09-06 16:06:26 -07:00
itsmattkc 9f8ffe1fc0 config: rename entry to force refresh on other systems 2022-08-11 08:35:17 -07:00
itsmattkc 3948b77543 viewer: allow customizing subtitle font
Fixes #1980
2022-07-23 13:49:02 -07:00
itsmattkc ac207e8fe7 timeline: implement add default transition
Fixes #1939
2022-06-28 12:09:10 -07:00
itsmattkc abb9c409e2 sequence: add test preview option 2022-05-29 09:20:12 -07:00
itsmattkc 4b366a9b73 update copyright year to 2022 2022-05-10 10:38:56 -07:00
itsmattkc 5bed4396ea use audioprocessor to match device's output 2022-05-05 16:32:17 -07:00
itsmattkc b290c4d007 audio: extended support for planar/packed formats 2022-05-03 13:41:27 -07:00
itsmattkc ef515579df completed audio recording implementation 2022-05-02 17:05:11 -07:00
itsmattkc 026cc9f064 config: add default recording format 2022-05-02 16:07:43 -07:00
itsmattkc 838017a468 config: set default marker color to lime
This feels slightly closer to the existing color
2022-05-01 11:16:13 -07:00
ThomasWilshaw 02b9a38737 Merge branch 'master' into marker 2022-01-28 22:30:29 +00:00
itsmattkc cfab883374 use config for viewer reassoc
Fixes #1661
2021-12-02 13:15:09 -08:00
Thomas Wilshaw e606c156c5 Cleanup for review 2021-11-09 11:59:29 +00:00
Thomas Wilshaw 374b97b6a5 Add default marker color to config 2021-10-22 22:15:53 +01:00
itsmattkc 4cbc93e947 config: change default setting 2021-10-06 13:07:12 -07:00
itsmattkc 2acf261ebf use enum for color coding 2021-10-06 13:06:34 -07:00
itsmattkc 7b65ecace5 implemented color picker in dialog
Fixes #1757
2021-10-01 15:41:24 -07:00
itsmattkc 3cc1bfb249 cache: increase default cache length 2021-09-29 01:37:43 -07:00
itsmattkc e101f3f4fe viewer: add option to stop playback on last frame
Fixes #1685
2021-09-22 19:40:22 -07:00
itsmattkc ba0401ff06 timeline: add optional showing clip while dragging 2021-09-07 18:06:53 -07:00
itsmattkc e433d7c374 Merge branch 'master' of https://github.com/olive-editor/olive 2021-07-24 09:37:17 -07:00
itsmattkc d0e7258301 added welcome dialog 2021-07-23 17:46:42 -07:00
itsmattkc db29dfdf1a viewer: use auto-cache as sequence parameter 2021-07-23 14:55:19 -07:00
itsmattkc febb5b0d25 config: startup option for autocache pause
Makes debugging easier
2021-05-10 10:40:17 +10:00
itsmattkc 77d4b18a60 updated copyright year for 2021 [skip ci] 2021-04-17 18:56:50 +10:00