Author Topic: MIDI Piano  (Read 2521 times)

Patrice Terrier

  • Administrator
  • *****
  • Posts: 951
    • zapsolution
MIDI Piano
« on: June 11, 2016, 06:50:16 pm »
This is the C++ 64-bit version, of the 32-bit custom control "PBPiano" written in PowerBASIC by Borje Hagsten.

The original 32-bit source code can be found there.

Screen shot of the 64-bit version


It's a virtual midi keyboard custom control.


The attached project has been done using the free version of Visual Studio 2017 community

...

« Last Edit: April 14, 2017, 07:14:42 pm by Patrice Terrier »
Patrice
(Always working with the latest Windows version available...)

Patrice Terrier

  • Administrator
  • *****
  • Posts: 951
    • zapsolution
MIDI Piano (skinned version)
« Reply #1 on: April 16, 2017, 05:52:47 pm »
This is the skinned version, the main EXE size is only 36 Kb (almost 1/3 of the original PB's 32-bit version).



If you want to disable the skin engine, just REM out the lines shown below in blue.

        if (skInitEngine (L"Reader.sks", L"")) {               // REM out these 2 lines if you want
            if (skSkinWindow(gP.hMain, (WCHAR*) SYSTOOLTIP)) { // to disable the WinLIFT skin engine.

                // Show the main window
                ShowWindow(gP.hMain, nCmdShow);
                UpdateWindow(gP.hMain);

                while (GetMessage(&msg, NULL, 0, 0)) {
                    TranslateMessage(&msg);
                    DispatchMessage(&msg);
                }
            }
        }
Patrice
(Always working with the latest Windows version available...)

Patrice Terrier

  • Administrator
  • *****
  • Posts: 951
    • zapsolution
Re: MIDI Piano
« Reply #2 on: April 18, 2017, 12:00:54 pm »
Quote
I have your versions of MIDIpiano working on both WinDev 21 and Visual Studio 2017. They are an excellent tutorial between PB, C and P-Code.
Chris Maher

Chris,
You are right, the core API SDK syntax is the same on all of them, this is the only common denominator understood by all programming languages.
And that is the only way to { easily } switch between all of them.  8)
Patrice
(Always working with the latest Windows version available...)