bayerutils: add new plugin with bayer2gray, to do caps conversion

This is a convenience function to avoid using a capssetter when we want to treat
Bayer as gray. In the future we can add properties to balance each element of the
CFA.

Note there's a bug with the in-place transform, so currently a memcpy is being used.
This commit is contained in:
Joshua M. Doe
2020-02-27 10:11:53 -05:00
parent 37aaea1022
commit 8ff872e634
4 changed files with 480 additions and 0 deletions

View File

@@ -0,0 +1,27 @@
set (SOURCES
gstbayer2gray.c
)
set (HEADERS
gstbayer2gray.h)
include_directories (AFTER
)
set (libname libgstbayerutils)
add_library (${libname} MODULE
${SOURCES}
${HEADERS})
target_link_libraries (${libname}
${GLIB2_LIBRARIES}
${GOBJECT_LIBRARIES}
${GSTREAMER_LIBRARY}
${GSTREAMER_BASE_LIBRARY}
${GSTREAMER_VIDEO_LIBRARY})
set (pdbfile "${CMAKE_CURRENT_BINARY_DIR}/\${CMAKE_INSTALL_CONFIG_NAME}/${libname}.pdb")
install (FILES ${pdbfile} DESTINATION lib/gstreamer-1.0 COMPONENT pdb)
install(TARGETS ${libname}
LIBRARY DESTINATION lib/gstreamer-1.0)