Files
GVFG_Standalone/GVFG_SDK/helpers/gvfg_playback/CMakeLists.txt
T
Mark.lin 5ebe03a2bb Consolidate playback APIs and add standalone OSD bitmap rendering
- move public PCM, image and presentation types into gvfg_playback.h and remove the separate backend headers from source and installation

- keep WASAPI and D3D backends private while preserving the existing public type names, fields and static backend integration

- move detailed preview delivery counters into a private header and expose their playback query only through the Debug diagnostics API

- retain public preview information and basic presentation statistics, mark EQUEUE_FULL as reserved, and document capacity limits as advanced settings with recommended defaults

- refresh customer guides, API reference and error handling for the single-header interface, presentation counter limits and EAUDIO handle-recreation policy

- add SDK-owned standalone premultiplied BGRA text rendering with transparent backgrounds, measured dimensions, thread-local snapshot lifetime and validated output bounds

Validation: git diff --cached --check passed. Release gvfg_playback and Customer Sample builds, standalone C/C++ header checks, Debug playback syntax checks and Release export inspection passed earlier in this session. Final follow-up changes affect comments and documentation only. No runtime or hardware playback validation was performed. The existing Release gvfg target was also checked and was up to date. OSD rendering changes were source-reviewed; no new bitmap or hardware test was run in this commit pass. Capture debug exports are unchanged.
2026-11-04 16:53:41 +08:00

48 lines
1.8 KiB
CMake

# Public playback DLL; backend libraries remain implementation details.
enable_language(RC)
add_library(gvfg_playback SHARED
gvfg_playback.def
include/gvfg_playback.h
src/gvfg_playback.cpp
src/playback_timing.h
src/playback_debug.h
src/signal_card.h
src/signal_card.cpp
src/signal_card.rc
)
set_target_properties(gvfg_playback PROPERTIES AUTOMOC OFF AUTOUIC OFF AUTORCC OFF)
target_include_directories(gvfg_playback
PUBLIC
${CMAKE_CURRENT_SOURCE_DIR}/include
PRIVATE
${CMAKE_CURRENT_SOURCE_DIR}/src
${CMAKE_CURRENT_SOURCE_DIR}/../gvfg_audio_playback/src
${CMAKE_CURRENT_SOURCE_DIR}/../gvfg_preview/src
)
target_compile_definitions(gvfg_playback PRIVATE GVFG_PLAYBACK_BUILD
GVFG_INTERNAL_DIAGNOSTICS=$<IF:$<CONFIG:Debug>,1,0>)
target_link_libraries(gvfg_playback PRIVATE gvfg_audio_playback gvfg_preview user32 gdi32 comctl32)
if(MSVC)
target_compile_options(gvfg_playback PRIVATE /utf-8 /EHsc)
endif()
if(MSVC AND GVFG_MINGW_DLLTOOL)
add_custom_command(TARGET gvfg_playback POST_BUILD
COMMAND "${GVFG_MINGW_DLLTOOL}"
-d "${CMAKE_CURRENT_SOURCE_DIR}/gvfg_playback.def"
-D gvfg_playback.dll -l libgvfg_playback.dll.a
WORKING_DIRECTORY "${CMAKE_ARCHIVE_OUTPUT_DIRECTORY}"
COMMENT "Generating MinGW import library for gvfg_playback.dll"
VERBATIM
)
install(FILES "${CMAKE_ARCHIVE_OUTPUT_DIRECTORY}/libgvfg_playback.dll.a"
DESTINATION ${CMAKE_INSTALL_LIBDIR})
endif()
install(TARGETS gvfg_playback
RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR})
# The unified public header contains all playback types and declarations.
install(FILES include/gvfg_playback.h
DESTINATION ${CMAKE_INSTALL_INCLUDEDIR})
# This README describes private internals. Customer guides are installed by
# the SDK root with the same relative layout as docs/.