[c-host] actually use the 2nd LGMP frame
This commit is contained in:
1 parent
c7aa8871e4
commit
a75b95694b
2 files changed
+3
-7
No files matched your search
+2
-6
@@ -107,13 +107,9 @@ static int frameThread(void * opaque)
|
||||
|
||||
bool frameValid = false;
|
||||
bool repeatFrame = false;
|
||||
int frameIndex = 0;
|
||||
CaptureFrame frame = { 0 };
|
||||
const long pageSize = sysinfo_getPageSize();
|
||||
|
||||
(void)frameIndex;
|
||||
(void)repeatFrame;
|
||||
|
||||
while(app.running)
|
||||
{
|
||||
switch(app.iface->waitFrame(&frame))
|
||||
@@ -164,8 +160,8 @@ static int frameThread(void * opaque)
|
||||
|
||||
// we increment the index first so that if we need to repeat a frame
|
||||
// the index still points to the latest valid frame
|
||||
if (frameIndex++ == LGMP_Q_FRAME_LEN)
|
||||
frameIndex = 0;
|
||||
if (app.frameIndex++ == LGMP_Q_FRAME_LEN)
|
||||
app.frameIndex = 0;
|
||||
|
||||
KVMFRFrame * fi = lgmpHostMemPtr(app.frameMemory[app.frameIndex]);
|
||||
switch(frame.format)
|
||||
|
||||
Reference in new issue
Block a user