Skip to content

Commit b7419e9

Browse files
committed
fixed hasDsiplay()
1 parent aa34e85 commit b7419e9

File tree

1 file changed

+12
-5
lines changed

1 file changed

+12
-5
lines changed

src/DMD.cpp

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -291,13 +291,18 @@ bool DMD::IsFinding() { return m_finding; }
291291

292292
bool DMD::HasDisplay() const
293293
{
294+
if (m_pZeDMD != nullptr && m_rgb24DMDs.size() > 0)
295+
{
296+
return true;
297+
}
298+
294299
#if !( \
295300
(defined(__APPLE__) && ((defined(TARGET_OS_IOS) && TARGET_OS_IOS) || (defined(TARGET_OS_TV) && TARGET_OS_TV))) || \
296301
defined(__ANDROID__))
297-
return (m_pZeDMD != nullptr) || (m_pPixelcadeDMD != nullptr);
298-
#else
299-
return (m_pZeDMD != nullptr);
302+
return (m_pPixelcadeDMD != nullptr);
300303
#endif
304+
305+
return false;
301306
}
302307

303308
bool DMD::HasHDDisplay() const
@@ -793,7 +798,8 @@ void DMD::ZeDMDThread()
793798
m_pZeDMD->SetFrameSize(width, height);
794799
}
795800

796-
Log(DMDUtil_LogLevel_DEBUG, "ZeDMD: Render frame buffer position %d at real buffer postion %d", bufferPosition, bufferPositionMod);
801+
Log(DMDUtil_LogLevel_DEBUG, "ZeDMD: Render frame buffer position %d at real buffer postion %d", bufferPosition,
802+
bufferPositionMod);
797803

798804
bool update = false;
799805
if (m_pUpdateBufferQueue[bufferPositionMod]->depth != 24)
@@ -958,7 +964,8 @@ void DMD::SerumThread()
958964

959965
if (result != IDENTIFY_NO_FRAME)
960966
{
961-
Log(DMDUtil_LogLevel_DEBUG, "Serum: Got PUP scene %d, frame %d colorized", prevTriggerId, sceneCurrentFrame - 1);
967+
Log(DMDUtil_LogLevel_DEBUG, "Serum: Got PUP scene %d, frame %d colorized", prevTriggerId,
968+
sceneCurrentFrame - 1);
962969
sceneUpdate->depth = m_pGenerator->getDepth();
963970
sceneUpdate->hasData = true;
964971
QueueSerumFrames(sceneUpdate, flags & FLAG_REQUEST_32P_FRAMES, flags & FLAG_REQUEST_64P_FRAMES);

0 commit comments

Comments
 (0)