Skip to content

Commit 25a887d

Browse files
committed
pwm: Fall back to 2-bit ID frame when PinMAME API isn't up-to-date yet.
1 parent 477c808 commit 25a887d

File tree

1 file changed

+4
-7
lines changed

1 file changed

+4
-7
lines changed

LibDmd/DmdDevice/DmdDevice.cs

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -305,13 +305,10 @@ public void RenderGray8(DmdFrame frame, DmdFrame identifyFrame)
305305
Init();
306306
}
307307
_passthroughGray8Source.NextFrame(frame);
308-
switch (identifyFrame.BitLength) {
309-
case 2:
310-
_passthroughGray2Source.NextFrame(identifyFrame);
311-
break;
312-
case 4:
313-
_passthroughGray4Source.NextFrame(identifyFrame);
314-
break;
308+
if (identifyFrame.BitLength == 4) {
309+
_passthroughGray4Source.NextFrame(identifyFrame);
310+
} else {
311+
_passthroughGray2Source.NextFrame(identifyFrame);
315312
}
316313
}
317314

0 commit comments

Comments
 (0)