Skip to content

libobs: image loader's WIC fallback behind graphics-ffmpeg-host.h, portable obs_bswap16 (#872) - #2125

Merged
zackees merged 4 commits into
masterfrom
facade/872-graphics-ffmpeg
Oct 24, 2026
Merged

zackees merged 4 commits into
masterfrom
facade/872-graphics-ffmpeg

Conversation

@zackees

@zackees zackees commented Oct 24, 2026

Copy link
Copy Markdown
Member

Refs #872 (slice 1 of 3: graphics-ffmpeg.c.h and libobs-media.pch.h).

  • graphics-ffmpeg-host.h: gs_image_host_fallback_load(), the second decoder for files FFmpeg can't load. graphics-ffmpeg-host-windows.c.h: the WIC/JPEG XR loader and its PQ→scRGB helpers, moved verbatim (only wic_image_init renamed and its unused info parameter dropped). graphics-ffmpeg-host-posix.c.h: returns NULL, as before.
  • obs_bswap16: one portable shift/or expression instead of _byteswap_ushort / __builtin_bswap16 by compiler.
  • wincodec.h + windowscodecs.lib move from the media PCH to the Windows host PCH. New groups registered in libobs/build/source-sets.json (Windows set; macOS and Linux sets), so CMake, cmake/cross and the Rust builds that read the manifest pick them up. Public headers untouched.
  • Baseline: graphics-ffmpeg.c.h, libobs-media.pch.h removed.

RED: 4f1112c adds test_graphics_ffmpeg_host (Tier 2: POSIX fallback loads nothing and leaves the outputs alone); fails to build.
GREEN: next commits. Locally the new test and all test_image_* pass; cross win-x64 + mac-arm64 compile. Local-only failures are the same set as on unrelated branches (deinterlace field order, native-core canvas/shutdown/audio, test_output_end_capture_thread_join).

Tiers 1/3/4 n/a (C restructuring, no behavior change).

@zackees
zackees enabled auto-merge October 24, 2026 10:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

1 participant