jsm174 / vpx-standalone-scripts

Table patches for VPX Standalone
https://github.com/vpinball/vpinball/tree/standalone/
31 stars 15 forks source link

DMD missing - Hollywood Heat (Gottlieb 1986) #12

Closed francisdb closed 1 year ago

francisdb commented 1 year ago

No DMD visible but might be because you have not implemented segment displays? Previous tips for showing the DMD don't help.

2023-06-09 12:17:12.878 INFO  [4437636] [VPinMAMEController::OnDisplayAvailable@64] index=0, displayCount=2, type=0, top=0, left=0, width=0, height=0, depth=0, length=20
2023-06-09 12:17:12.878 INFO  [4437636] [VPinMAMEController::OnDisplayAvailable@64] index=1, displayCount=2, type=0, top=2, left=0, width=0, height=0, depth=0, length=20
jsm174 commented 1 year ago

Alphanumeric code is working on the libpinmame side as shown from above, but some just tables don't render them in desktop mode.

Many of the tables that don't draw them in desktop, do actually draw them when the table is in vr mode, so it seems to me like it has to be possible.

If you look at Rock (Gottlieb 1985) v4.vpx, you'll see them working.

Screenshot 2023-06-09 at 7 09 17 AM

francisdb commented 1 year ago

DMD should look like this in desktop mode https://www.youtube.com/watch?v=mct3HxFXB7U

Any reason why the ImplicitDMD_Init does not add it?

image
jsm174 commented 1 year ago

DMDs are rendered into a buffer of pixels. The pixels are then rendered in a textbox.

Alphanumerics are physically drawn.

Look at Rock's vbs code:

'*****************
' Leds Display
'*****************

Dim Digits(40)

Digits(0) = Array(a00, a05, a0c, a0d, a08, a01, a06, a0f, a02, a03, a04, a07, a0b, a0a, a09, a0e)
Digits(1) = Array(a10, a15, a1c, a1d, a18, a11, a16, a1f, a12, a13, a14, a17, a1b, a1a, a19, a1e)
Digits(2) = Array(a20, a25, a2c, a2d, a28, a21, a26, a2f, a22, a23, a24, a27, a2b, a2a, a29, a2e)
Digits(3) = Array(a30, a35, a3c, a3d, a38, a31, a36, a3f, a32, a33, a34, a37, a3b, a3a, a39, a3e)

.
.

Sub UpdateLeds
    Dim ChgLED, ii, num, chg, stat, obj
    ChgLED = Controller.ChangedLEDs(&Hffffffff, &Hffffffff)
    If Not IsEmpty(ChgLED)Then
        For ii = 0 To UBound(chgLED)
            num = chgLED(ii, 0):chg = chgLED(ii, 1):stat = chgLED(ii, 2)
            For Each obj In Digits(num)
                If chg And 1 Then obj.State = stat And 1
                chg = chg \ 2:stat = stat \ 2
            Next
        Next
    End If
End Sub

The table contains objects for each segment..

francisdb commented 1 year ago

I guess this is a normal DMD emulating digits.

image
jsm174 commented 1 year ago

if you wanted to fake alphanumerics into a dmd buffer, we would have to write code in standalone's VPinMAMEController similar to what dmd-ext is doing, ie:

https://github.com/freezy/dmd-extensions/blob/313db06aea44a883dc90416340db4e68ec48c289/LibDmd/DmdDevice/DmdDevice.cs#L878

and

https://github.com/vpinball/pinmame/blob/master/ext/dmddevice/usbalphanumeric.h

francisdb commented 1 year ago

So these YouTube movies use dmd-ext? I think I'm not really following. Anyway I guess I'll just skip this table for now.