Initial commit

This commit is contained in:
Gwen Gourevich
2021-10-27 10:34:18 +02:00
parent 43ad18eb04
commit c5f4f6ba25
199 changed files with 73169 additions and 0 deletions

13
LIB386/LIB_MIX/BUILD.BAT Normal file
View File

@@ -0,0 +1,13 @@
call watcom10
pkunzip -o obj >NUL
wmake
pkzip -m obj *.obj >NUL
call watcom9
pkunzip -o obj9 >NUL
wmake WATCOM9=yes
pkzip -m obj9 *.obj >NUL
call watcom10

View File

@@ -0,0 +1,3 @@
pkunzip -o obj >NUL
wmake /f mix_dll.mak
pkzip -m obj *.obj >NUL

85
LIB386/LIB_MIX/LIB_MIX.H Normal file
View File

@@ -0,0 +1,85 @@
#ifdef WATCOM9
#pragma library ("f:\projet\lib386\lib_mix\lb9_mix.lib");
#else
#pragma library ("f:\projet\lib386\lib_mix\lib_mix.lib");
#endif
extern LONG Mixer_Driver_Enable;
/*----------------------------------------------------------------------*/
/* MixerAskVars : Get list of vars for the lib */
/* */
/* listidentifier : pointer to an array of string*/
/* pointers, each string */
/* contains the name of the var */
/* to initialise for the DLL */
/* ptrvars : pointer to an array of DWORD to */
/* store the value of each var in */
/* listidentifier */
/* */
/* Returns : nothing */
/*----------------------------------------------------------------------*/
void MixerAskVars( char ***listidentifier,
LONG **ptrvars );
/*----------------------------------------------------------------------*/
/* MixerChangeVolume : Change the hardware volume for MIDI, */
/* WAVE, CD, Line, Master */
/* */
/* VolWave : Volume for WAVE (0-255) */
/* VolMidi : Volume for MIDI (0-255) */
/* VolCD : Volume for CD (0-255) */
/* VolLine : Volume for LINE (0-255) */
/* VolMaster : Volume for MASTER (0-255) */
/* */
/* NOTE : A VOLUME OF -1 MEANS NO CHANGE */
/* */
/* Returns : nothing */
/*----------------------------------------------------------------------*/
void MixerChangeVolume( LONG VolWave,
LONG VolMidi,
LONG VolCD,
LONG VolLine,
LONG VolMaster );
/*----------------------------------------------------------------------*/
/* MixerGetVolume : Get the hardware volume for MIDI, WAVE, */
/* CD, Line and Master */
/* */
/* VolWave : ptr on Volume for WAVE (0-255) */
/* VolMidi : ptr on Volume for MIDI (0-255) */
/* VolCD : ptr on Volume for CD (0-255) */
/* VolLine : ptr on Volume for LINE (0-255) */
/* VolMaster : ptr on Volume for MASTER (0-255) */
/* */
/* NOTE : A NULL PTR MEANS NO GET */
/* */
/* Returns : nothing */
/*----------------------------------------------------------------------*/
void MixerGetVolume( LONG *VolWave,
LONG *VolMidi,
LONG *VolCD,
LONG *VolLine,
LONG *VolMaster );
/*----------------------------------------------------------------------*/
/* MixerGetInfo : Get the hardware volume capabilities */
/* */
/* VolWave : ptr on Volume for WAVE (0/1) */
/* VolMidi : ptr on Volume for MIDI (0/1) */
/* VolCD : ptr on Volume for CD (0/1) */
/* VolLine : ptr on Volume for LINE (0/1) */
/* VolMaster : ptr on Volume for MASTER (0/1) */
/* */
/* NOTE : A NULL PTR MEANS NO GET */
/* */
/* Returns : nothing */
/*----------------------------------------------------------------------*/
void MixerGetInfo( LONG *VolWave,
LONG *VolMidi,
LONG *VolCD,
LONG *VolLine,
LONG *VolMaster );

54
LIB386/LIB_MIX/MAKEFILE Normal file
View File

@@ -0,0 +1,54 @@
# name the compiler
!ifdef %HOME
!ifeq WATCOM9 yes
CC = c:\compil\watcom\bin\wcc386p
WL = c:\compil\watcom\binb\wlib
!else
CC = c:\compil\watcom10\binb\wcc386
WL = c:\compil\watcom10\binb\wlib
!endif
!else
!ifeq WATCOM9 yes
CC = f:\compil\watcom\bin\wcc386p
WL = f:\compil\watcom\binb\wlib
!else
CC = f:\compil\watcom10\binb\wcc386
WL = f:\compil\watcom10\binb\wlib
!endif
!endif
ASM = ml
!ifeq WATCOM9 yes
CFLAGS = /oeaxt /zp2 /4s /zq /s /DWATCOM9
!else
CFLAGS = /oeaxt /zp2 /5s /zq /s
!endif
LFLAGS = /c /q /b /n
#AFLAGS = /m2 /mx /z /zi /t /jMASM51 /jQUIRKS
AFLAGS = /Cx /Zm /c /W0 /Sa /DNoLanguage=SYSCALL /Djumps=;
OBJETS1 = mixer.obj mixer_i.obj
OBJETS2 =
OBJETS3 =
OBJETS4 =
!ifeq WATCOM9 yes
LIB = LB9_MIX
!else
LIB = LIB_MIX
!endif
$(LIB).LIB: $(OBJETS1) $(OBJETS2) $(OBJETS3) $(OBJETS4)
@echo $(OBJETS1) > clibmak.rsp
@$(WL) $(LIBFLAGS) $(LIB) @clibmak.rsp
@del clibmak.rsp
@prntitre M "$(LIB) OK"
.asm.obj:
@PRNTITRE M "$*.ASM"
@$(ASM) $(AFLAGS) $*.ASM
.c.obj:
@PRNTITRE M "$*.C"
@$(CC) $(CFLAGS) $*

50
LIB386/LIB_MIX/MIXER.C Normal file
View File

@@ -0,0 +1,50 @@
/*ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ*
SAMP.C 386
(c) Adeline 1993
*ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ*/
#include "\projet\lib386\lib_sys\adeline.h"
#include "\projet\lib386\lib_sys\lib_sys.h"
#include "\projet\lib386\lib_mix\lib_mix.h"
#include <stdlib.h>
#include <stdio.h>
#include <dos.h>
#include <i86.h>
char *MixerError = "Error MixerDriver:";
extern void *Mixer_listfcts;
extern LONG Mixer_Driver_Enable;
/*-------------------------------------------------------------------------*/
LONG MixerInitDLL(char *driverpathname)
{
char *dll, *drvr;
//
// Load driver file
//
dll = FILE_read( driverpathname, NULL);
if (dll==NULL)
{
printf("%s Could not load driver '%s'.\n", MixerError, driverpathname );
return FALSE ;
}
drvr=DLL_load(dll,DLLMEM_ALLOC | DLLSRC_MEM,NULL);
if (drvr==NULL)
{
printf("%s Invalid DLL image.\n", MixerError );
return FALSE ;
}
Free(dll);
Mixer_listfcts = *(void **)drvr;
printf("%s", drvr+4);
return (Mixer_Driver_Enable = TRUE);
}
/*-------------------------------------------------------------------------*/

1384
LIB386/LIB_MIX/MIXER_A.ASM Normal file

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,83 @@
;*ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ*
; MIXER_I.ASM 386
; (c) Adeline 1993
;*ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ*
;*--------------------------------------------------------------------------*
.386
jumps
.model SMALL, SYSCALL
.DATA
PUBLIC NoLanguage Mixer_listfcts
PUBLIC NoLanguage Mixer_Driver_Enable
Mixer_listfcts dd 0
Mixer_Driver_Enable dd 0
.CODE
PUBLIC NoLanguage MixerAskVars
PUBLIC NoLanguage MixerChangeVolume
PUBLIC NoLanguage MixerGetVolume
;----------------------------------------------------------------------------
;----------------------------------------------------------------------------
MixerCallFuncs PROC
cmp byte ptr[Mixer_Driver_Enable], 0
je return
shl eax, 2
add eax, dword ptr[Mixer_listfcts]
jmp dword ptr[eax]
return:
ret
MixerCallFuncs ENDP
;----------------------------------------------------------------------------
;----------------------------------------------------------------------------
MixerAskVars PROC
mov eax, 0
jmp MixerCallFuncs
MixerAskVars ENDP
;----------------------------------------------------------------------------
MixerChangeVolume PROC
mov eax, 1
jmp MixerCallFuncs
MixerChangeVolume ENDP
;----------------------------------------------------------------------------
MixerGetVolume PROC
mov eax, 2
jmp MixerCallFuncs
MixerGetVolume ENDP
;----------------------------------------------------------------------------
MixerGetInfo PROC
mov eax, 3
jmp MixerCallFuncs
MixerGetInfo ENDP
;----------------------------------------------------------------------------
END

View File

@@ -0,0 +1,52 @@
AFLAGS = /Cx /Zm /c /W0 /Sa /DNoLanguage=SYSCALL /Djumps=;
LINKDIR = format os2 lx dll
dll: m_pas.dll m_mwss.dll m_sb2cd.dll m_sbpro.dll m_sb16.dll m_gold.dll
#
# Mixer driver: AD1848 SoundPort, Microsoft Windows Sound System
#
m_mwss.dll: mixer_a.asm
ml $(AFLAGS) /DMWSS mixer_a.asm
wlink n m_mwss.dll f mixer_a $(LINKDIR)
#
# Mixer driver: Pro Audio Spectrum
#
m_pas.dll: mixer_a.asm
ml $(AFLAGS) /DPAS mixer_a.asm
wlink n m_pas.dll f mixer_a $(LINKDIR)
#
# Mixer driver: Sound Blaster 2 CD Interface card
#
m_sb2cd.dll: mixer_a.asm
ml $(AFLAGS) /DSB2CD mixer_a.asm
wlink n m_sb2cd.dll f mixer_a $(LINKDIR)
#
# Mixer driver: Sound Blaster Pro
#
m_sbpro.dll: mixer_a.asm
ml $(AFLAGS) /DSBPRO mixer_a.asm
wlink n m_sbpro.dll f mixer_a $(LINKDIR)
#
# Mixer driver: Sound Blaster 16
#
m_sb16.dll: mixer_a.asm
ml $(AFLAGS) /DSB16 mixer_a.asm
wlink n m_sb16.dll f mixer_a $(LINKDIR)
#
# Mixer driver: Yamaha Gold, Adlib Gold
#
m_gold.dll: mixer_a.asm
ml $(AFLAGS) /DGOLD mixer_a.asm
wlink n m_gold.dll f mixer_a $(LINKDIR)