mirror of
https://github.com/raspberrypi/userland.git
synced 2025-12-06 04:49:12 +00:00
Update RaspiStill framework to provide access to the new EGL image targets that provide a fastpath for mapping the individual YUV planes to one byte per pixel GL_LUMINANCE buffers. These are still accessed as OES textures so this is effectively a greyscale image created from a single plane of a MMAL buffer. Also added some example code (yuv, sobel) that demonstrates how to use the new EGL image targets. Also, add -gc to the command line to capture the GL frame-buffer as a TGA file. Thanks to Tim Gover
33 lines
1010 B
CMake
33 lines
1010 B
CMake
|
|
# raspistill/raspivid/raspiyuv
|
|
|
|
SET(COMPILE_DEFINITIONS -Werror)
|
|
|
|
include_directories(${CMAKE_SOURCE_DIR}/host_applications/linux/libs/bcm_host/include)
|
|
include_directories(${CMAKE_SOURCE_DIR}/host_applications/linux/apps/raspicam/)
|
|
|
|
set (GL_SCENE_SOURCES
|
|
gl_scenes/models.c
|
|
gl_scenes/mirror.c
|
|
gl_scenes/yuv.c
|
|
gl_scenes/sobel.c
|
|
gl_scenes/square.c
|
|
gl_scenes/teapot.c)
|
|
|
|
set (COMMON_SOURCES
|
|
RaspiCamControl.c
|
|
RaspiCLI.c
|
|
RaspiPreview.c)
|
|
|
|
add_executable(raspistill ${COMMON_SOURCES} RaspiStill.c RaspiTex.c RaspiTexUtil.c tga.c ${GL_SCENE_SOURCES})
|
|
add_executable(raspiyuv ${COMMON_SOURCES} RaspiStillYUV.c)
|
|
add_executable(raspivid ${COMMON_SOURCES} RaspiVid.c)
|
|
|
|
set (MMAL_LIBS mmal_core mmal_util mmal_vc_client)
|
|
|
|
target_link_libraries(raspistill ${MMAL_LIBS} vcos bcm_host GLESv2 EGL m)
|
|
target_link_libraries(raspiyuv ${MMAL_LIBS} vcos bcm_host)
|
|
target_link_libraries(raspivid ${MMAL_LIBS} vcos bcm_host)
|
|
|
|
install(TARGETS raspistill raspiyuv raspivid RUNTIME DESTINATION bin)
|