mirror of
https://github.com/hyperion-project/hyperion.ng.git
synced 2025-03-01 10:33:28 +00:00
Dynamic loading of the Dispmanx Grabber (#1440)
* BCM dynamic loading * cleanup * better handle start of dispmanx * set GrabberWrapper pointer to null on exit * Update DispmanxFrameGrabber.cpp
This commit is contained in:
@@ -1,14 +1,3 @@
|
||||
# Find the BCM-package (VC control)
|
||||
if (ENABLE_DISPMANX)
|
||||
if ( "${PLATFORM}" MATCHES rpi)
|
||||
find_package(BCM REQUIRED)
|
||||
include_directories(${BCM_INCLUDE_DIRS})
|
||||
else()
|
||||
set(BCM_INCLUDE_DIRS "")
|
||||
set(BCM_LIBRARIES "")
|
||||
endif()
|
||||
endif (ENABLE_DISPMANX)
|
||||
|
||||
# Define the current source locations
|
||||
|
||||
SET(CURRENT_HEADER_DIR ${CMAKE_SOURCE_DIR}/include/api)
|
||||
|
@@ -1679,10 +1679,13 @@ void JsonAPI::handleInputSourceCommand(const QJsonObject& message, const QString
|
||||
|
||||
#if defined(ENABLE_DISPMANX)
|
||||
DispmanxFrameGrabber* dispmanx = new DispmanxFrameGrabber();
|
||||
device = dispmanx->discover(params);
|
||||
if (!device.isEmpty() )
|
||||
if (dispmanx->isAvailable())
|
||||
{
|
||||
videoInputs.append(device);
|
||||
device = dispmanx->discover(params);
|
||||
if (!device.isEmpty() )
|
||||
{
|
||||
videoInputs.append(device);
|
||||
}
|
||||
}
|
||||
delete dispmanx;
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user