Mod Player asm/2

 BBS: Inland Empire Archive
Date: 11-30-92 (21:22)             Number: 381
From: RICH GELDREICH               Refer#: NONE
  To: ALL                           Recvd: NO  
Subj: Mod Player asm/2               Conf: (2) Quik_Bas
'<<Part 2 Starts Here>>
        Retf    8
ENDP    SetBuffers
;=====================================================================
PROC    GetCS
        Mov     ax, cs
        Retf    0
ENDP    GetCS
;=====================================================================
PROC    GetOF
        Mov     ax, offset NewInt8
        Retf    0
ENDP    GetOF
;=====================================================================
PROC    UnsignedComp
        Push    bp
        Mov     bp, sp
        Mov     ax, [ss:bp+08]
        Cmp     ax, [ss:bp+06]
        Jae     @@AboveOrEqual
        Xor     ax, ax
@@Back: Pop     bp
        Retf    4
@@AboveOrEqual:
        Mov     ax, 1
        Jmp     @@Back
ENDP    UnsignedComp
;=====================================================================
END
'<<-Cut Here->>

Finally, here's QBMPASM.OBJ for those without TASM:

To execute this script, save it to a file and type DEBUG < filename
where "filename" is the name of this script file.
E165"QBMPASM.OBJ" 0
E200".q..92bMh/LMnpa9/BJHcVs5....IJbQWx46/BrQZpaMgJaQU.WJZ7rQdxaPU"
E23D"6X9kY9WH..EdTGEyZl0l7KPk3qQhtGEHpYA6C...ZCHK8...U4W1..EVGdZA."
E27A"E/TFJFMF3/1x2F3N7a5..Gc4U.12UOKm..3w3F/FJE2EIEI3YkMS..6/..2IE"
E2B7".DM70.M.F57pHJ/pWOG..4wj.P/73..E.BA2G3BoG2xYH3N2H/RYJ/.EKE4/."
E2F4".2U0HJ2J0JZF4JYIHxJ..gDYA.../IkF3FpEHhM..k3YA.../IkF3FpH4tM.."
E331"c3YH.../kEJCBJG5tIF2BoHB/ZY/.EA6G...7O.F08f/2..........UwV5Rk"

E36E"l4OY/4MQl3KMF3JI/3IEl2HAV2G6V2F2F2F./2E.l1Dwk1CsU1CsE1BoE1Bk."
E3AB"1Ak.19gk09gk08cU08cU07YE07YE06U.06U.05Qk/5Qk/5MU/4MU/4ME/3IE/"
E3E8"3IE/2E./2E./2Ak.1Ak.1AU.06U.06U./2E./2E./2EE/3IE/3IE./2E./2E."
E425"xnDzwnDzwXDysXDysXDxoHDxoHDxk1Dwk1DwknCvgnCvgnCucXCucXCtYHCtY"
E462"HCsU1CsU1CrQnBrQnBqMXBqMHBpIHBpE1BoE1BnAnAn6XAm6HAl2HAk.1Akwm"
E49F"9jsW9ioG9hk09fgW8eY08bMG7YAW6V.d5EB3iNadXMjPaNes/1BY97ul1/2sy"
E4DC"Na7REgP/.smpa92gUMC6PVp5D1d94P./.wj99u/..smVS6..iYc5..U97ul1/"
E519"2skNad97u/5/gymE81kiMc/2..a9LpWgvV1TgcF6Ae..gcFAAe0/gcF8A8..A"
E556"u1/gcL4Yc5A3k.1D85/wFL8X..AWwmsOE.9LpWgjcF6gXF4Ab/n.QL8H..s4."
E593".fTzvQ42.3X/J/IQ6I3ElnEJ.3b1J/IgDI3El1FJ.3X2J/IQII3ElPFJ.3b4J"
E5D0"/IwPI3ElpFJ.3X5J/IwTI3El2GJ.3z6J/6VW0...o/"
E100 B8 0 3C BA 65 1 33 C9 CD "!rC" BE 0 2 50 BD FB 2 55 BF 88 90
E117 "W3" DB B1 FA 8A F0 80 C1 6 32 E4 AC "<9v" 8 "<Zv" 2 2C 6 2C
E12F 7 2C 2E E3 E8 D3 E0 A C6 AA 2 D8 92 "IIMu" E0 80 FB 0 75 9 5A
E147 59 5B B4 40 CD 21 73 7 B4 9 BA 58 1 CD 21 CD 20 7 "Error!$"
G
Q

        That is all.  This program is very big, so take your time
putting it together.  After posting this program, I re-downloaded
all of the messages and combined them just to make sure they were
uploaded correctly, so they will hopefully make it out to the inner
recesses of the FidoNET intact...

        I have spent _many_ months optimizing my MOD playing
algorithms so they would be efficient enough to do in almost all
QB.  On my 286/10, I've rated it to use about 95% processor time at
11,000 hertz.  This may not sound like much, but the all-assembler
version of this algorithm(which is used in my first demo that we
will be releasing under Renaissance) is extremely efficient - it can
play any MOD up to 65,535 hertz on my 286/10 (and still have about
25% processor time remaining!).  This test was done on my Tandy's
DMA DAC, which can play at very high sample rates.

        As I said in QBMP15.BAS, I currently have not been able to
test this program in QuickBASIC 4.5, only PDS.

        Have fun!

        Rich Geldreich

    PS. Some of the docs in the QB program wrapped, so be carefull
reconstucted the code.

--- MsgToss 2.0b
 * Origin: Computer Co-Op - Voorhees, NJ | Ted Hare (1:266/29)
Outer Court
Echo Basic Postings

Books at Amazon:

Back to BASIC: The History, Corruption, and Future of the Language

Hackers: Heroes of the Computer Revolution (including Tiny BASIC)

Go to: The Story of the Math Majors, Bridge Players, Engineers, Chess Wizards, Scientists and Iconoclasts who were the Hero Programmers of the Software Revolution

The Advent of the Algorithm: The Idea that Rules the World

Moths in the Machine: The Power and Perils of Programming

Mastering Visual Basic .NET