Added MaxSt's HQ3X filter

This commit is contained in:
pagefault
2003-07-16 21:10:05 +00:00
parent e36ddb574a
commit 0ff6b8a6ac
12 changed files with 5486 additions and 120 deletions

View File

@@ -70,7 +70,7 @@ EXTSYM soundon, StereoSound, SoundCompD, SoundQuality, MusicRelVol
EXTSYM endprog, continueprog, spcBuffera, spcRamcmp, cbitmode, makepal
EXTSYM t1cc, LoadDir, SRAMDir, LoadDrive,SRAMDrive, initsnes, romloadskip
EXTSYM fname, makeextension, sram, clearmem2, loadfileGUI, GUIloadfailed
EXTSYM SetupROM, CheckROMType, romdata, ForcePal, ramsize, ramsizeand, curromsize
EXTSYM SetupROM,CheckROMType, romdata, ForcePal, ramsize, ramsizeand, curromsize
EXTSYM romispal, totlines, cfgloadsdir, init65816, procexecloop
EXTSYM spcRam, spcPCRam, spcS, spcRamDP, spcA, spcX, spcY, spcP, spcNZ
EXTSYM Voice0Status, Voice1Status, Voice2Status, Voice3Status, Voice4Status
@@ -158,6 +158,7 @@ EXTSYM TCPIPSendPacket,TCPIPSendPacketUDP
EXTSYM TCPIPDisconnect,TCPIPStatus
EXTSYM TCPIPStoreByte
EXTSYM TCPIPGetByte,GUIBIFIL
EXTSYM GUIHQ3X
EXTSYM firstsaveinc
EXTSYM nssdip1,nssdip2,nssdip3,nssdip4,nssdip5,nssdip6
%ifdef __LINUX__
@@ -585,7 +586,7 @@ NEWSYM SmallMsgText, db 0
NEWSYM AllowMultipleInst, db 0
NEWSYM FilteredGUI, db 0
NEWSYM BilinearFilter, db 0
NEWSYM TripleBufferWin, db 0
NEWSYM hq3xFilter, db 0
NEWSYM ExclusiveSound, db 0
NEWSYM DisableScreenSaver, db 0
@@ -1540,6 +1541,7 @@ NEWSYM StartGUI
jmp .no2xSaIdis
.2xSaIdis
mov byte[En2xSaI],0
mov byte[hq3xFilter],0
.no2xSaIdis
cmp byte[En2xSaI],0
je .no2xsaidis
@@ -1547,9 +1549,16 @@ NEWSYM StartGUI
.no2xsaidis
cmp byte[En2xSaI],0
je .no2xsaien
mov byte[hq3xFilter],0
mov byte[scanlines],0
mov byte[antienab],0
.no2xsaien
cmp byte[hq3xFilter],0
je .nohq3x
mov byte[En2xSaI],0
mov byte[scanlines],0
mov byte[antienab],0
.nohq3x
;.dosport
mov ecx,64

View File

@@ -1019,6 +1019,8 @@ GUIVideoKeys:
jne .nofullscanlines
cmp byte[En2xSaI],0
jne .nofullscanlines
cmp byte[hq3xFilter],0
jne .nofullscanlines
call ClearScreen
GUIkeystoggleoptn byte[scanlines],1
%ifdef __MSDOS__
@@ -1043,6 +1045,8 @@ GUIVideoKeys:
jne .nohalfscanlines
cmp byte[En2xSaI],0
jne .nohalfscanlines
cmp byte[hq3xFilter],0
jne .nohalfscanlines
call ClearScreen
GUIkeystoggleoptn byte[scanlines],3
%ifdef __MSDOS__
@@ -1058,6 +1062,8 @@ GUIVideoKeys:
jne .noquarterscanlines
cmp byte[En2xSaI],0
jne .noquarterscanlines
cmp byte[hq3xFilter],0
jne .noquarterscanlines
call ClearScreen
GUIkeystoggleoptn byte[scanlines],2
%ifdef __MSDOS__
@@ -1069,6 +1075,20 @@ GUIVideoKeys:
;call GUISetPal
%endif
.noquarterscanlines
cmp dh,'Q'
jne .nohq3xfilter
xor ebx,ebx
mov bl,[cvidmode]
cmp byte[GUIHQ3X+ebx],0
je .nohq3xfilter
xor byte[hq3xFilter],1
jz .nohq3xfilter
mov byte[scanlines],0
mov byte[cfgscanline],0
mov byte[En2xSaI],0
mov byte[antienab],0
mov byte[cfginterp],0
.nohq3xfilter
cmp dh,'X'
jne .no2xsai
xor ebx,ebx
@@ -1176,19 +1196,6 @@ GUIVideoKeys:
je .nobilinearfilter
xor byte[BilinearFilter],1
.nobilinearfilter
%ifdef __WIN32__
cmp dh,'T'
jne .notriplebufferwin
xor eax,eax
mov al,[cvidmode]
cmp byte[GUITBWVID+eax],0
je near .notriplebufferwin
xor byte[TripleBufferWin],1
; mov byte[vsyncon],0
; mov byte[cfgvsync],0
call initDirectDraw
.notriplebufferwin
%endif
%ifdef __MSDOS__
cmp dh,'T'
jne .notriplebuffer
@@ -1212,7 +1219,6 @@ GUIVideoKeys:
mov al,[vsyncon]
mov [cfgvsync],al
%ifdef __WIN32__
; mov byte[TripleBufferWin],0
call initDirectDraw
%endif
%ifdef __MSDOS__

View File

@@ -1380,6 +1380,21 @@ GUIWinClicked:
%%noclick
%endmacro
%macro GUIClickCButtonHQ 3
cmp eax,%1+1
jl %%noclick
cmp edx,%2+3
jl %%noclick
cmp eax,%1+6
jg %%noclick
cmp edx,%2+8
jg %%noclick
xor %3,1
jz %%noclick
mov byte[En2xSaI],0
%%noclick
%endmacro
%macro GUIClickCButtonT 4
cmp eax,%1+1
jl %%noclick
@@ -2301,8 +2316,8 @@ DisplayGUIVideoClick:
xor ebx,ebx
mov bl,[cvidmode]
cmp byte[GUISLVID+ebx],0
GUIClickCButton4 21,114,byte[scanlines],byte[cfgscanline],1
je near .nocheckboxb
GUIClickCButton4 21,114,byte[scanlines],byte[cfgscanline],1
.nocheckboxb
xor ebx,ebx
mov bl,[cvidmode]
@@ -2330,14 +2345,12 @@ DisplayGUIVideoClick:
GUIClickCButton4 61,114,byte[scanlines],byte[cfgscanline],3
GUIClickCButton4 101,114,byte[scanlines],byte[cfgscanline],2
.nohsline
%ifdef __WIN32__
xor ebx,ebx
mov bl,[cvidmode]
cmp byte[GUITBWVID+ebx],0
je near .notriplebufferwin
GUIClickCButtonf 11,123,byte[TripleBufferWin],initDirectDraw
.notriplebufferwin
%endif
cmp byte[GUIHQ3X+ebx],0
je .nocheckboxhq3x
GUIClickCButtonHQ 11,123,byte[hq3xFilter]
.nocheckboxhq3x
xor ebx,ebx
mov bl,[cvidmode]
cmp byte[GUI2xVID+ebx],0

View File

@@ -1643,6 +1643,7 @@ DisplayGUIVideo:
jmp .no2xSaIdis
.2xSaIdis
mov byte[En2xSaI],0
mov byte[hq3xFilter],0
.no2xSaIdis
cmp byte[En2xSaI],0
je .no2xsaidis
@@ -1650,9 +1651,16 @@ DisplayGUIVideo:
.no2xsaidis
cmp byte[En2xSaI],0
je .no2xsaien
mov byte[hq3xFilter],0
mov byte[scanlines],0
mov byte[antienab],0
.no2xsaien
cmp byte[hq3xFilter],0
je .nohq3xen
mov byte[En2xSaI],0
mov byte[scanlines],0
mov byte[antienab],0
.nohq3xen
; Video Modes List/Scanlines/Interpolation/Full(Small) Screen
GUIDrawWindowBox 5,GUIVideoDisp
mov byte[GUItextcolor],217
@@ -1687,12 +1695,6 @@ DisplayGUIVideo:
GUIOuttextwin2u 5,76,119,GUIVideoTexta2,0
GUIOuttextwin2u 5,116,119,GUIVideoTexta3,0
.notexta
xor eax,eax
mov al,[cvidmode]
cmp byte[GUITBWVID+eax],0
je near .nottbw
GUIOuttextwin2u 5,26,128,GUIVideoText7,0
.nottbw
xor eax,eax
mov al,[cvidmode]
cmp byte[GUI2xVID+eax],0
@@ -1758,6 +1760,12 @@ DisplayGUIVideo:
je .notext8
GUIOuttextwin2u 5,26,178,GUIVideoText8b,0
.notext8
xor eax,eax
mov al,[cvidmode]
cmp byte[GUIHQ3X+eax],0
je near .notext11
GUIOuttextwin2u 5,26,128,GUIVideoTexthq3x,1
.notext11
GUIOuttextwin2u 5,26,188,GUIVideoText8c,0
%ifndef __LINUX__
GUIOuttextwin2u 5,130,188,GUIVideoText9,0
@@ -1788,12 +1796,6 @@ DisplayGUIVideo:
GUIOuttextwin2 5,75,118,GUIVideoTexta2
GUIOuttextwin2 5,115,118,GUIVideoTexta3
.notextab
xor eax,eax
mov al,[cvidmode]
cmp byte[GUITBWVID+eax],0
je near .nottbwb
GUIOuttextwin2 5,25,127,GUIVideoText7
.nottbwb
xor eax,eax
mov al,[cvidmode]
cmp byte[GUI2xVID+eax],0
@@ -1859,6 +1861,12 @@ DisplayGUIVideo:
je .notext8b
GUIOuttextwin2 5,25,177,GUIVideoText8b
.notext8b
xor eax,eax
mov al,[cvidmode]
cmp byte[GUIHQ3X+eax],0
je near .notext11b
GUIOuttextwin2 5,25,127,GUIVideoTexthq3x
.notext11b
GUIOuttextwin2 5,25,187,GUIVideoText8c
%ifndef __LINUX__
GUIOuttextwin2 5,129,187,GUIVideoText9
@@ -1901,17 +1909,6 @@ DisplayGUIVideo:
.nocheckboxv2
GUIDisplayIconWin 5,101,114,[GUITemp]
.nocheckboxw
xor eax,eax
mov al,[cvidmode]
cmp byte[GUITBWVID+eax],0
je near .nocheckboxslw2
mov dword[GUITemp],GUIIconDataCheckBoxUC
cmp byte[TripleBufferWin],1
jne .nocheckboxslw
mov dword[GUITemp],GUIIconDataCheckBoxC
.nocheckboxslw
GUIDisplayIconWin 5,11,123,[GUITemp]
.nocheckboxslw2
xor eax,eax
mov al,[cvidmode]
cmp byte[GUI2xVID+eax],0
@@ -2031,6 +2028,17 @@ DisplayGUIVideo:
.nocheckbox3
GUIDisplayIconWin 5,11,98,[GUITemp]
.nocheckbox3b
xor eax,eax
mov al,[cvidmode]
cmp byte[GUIHQ3X+eax],0
je near .nocheckbox2hq3x
mov dword[GUITemp],GUIIconDataCheckBoxUC
cmp byte[hq3xFilter],0
je .nocheckbox1hq3x
mov dword[GUITemp],GUIIconDataCheckBoxC
.nocheckbox1hq3x
GUIDisplayIconWin 5,11,123,[GUITemp]
.nocheckbox2hq3x
DrawGUIWinBox 5,5,26,115,69,167
DrawSlideBarWin 5,117,34,[GUIcurrentvideoviewloc],[NumVideoModes],5,28,GUIVStA
cmp byte[GUICHold],5
@@ -2150,6 +2158,7 @@ GUIVideoTextd2 db 'SUPER 2XSAI ENGINE',0
GUIVideoTextbf db 'BILINEAR FILTER',0
GUIVideoText3 db 'INTERPOLATION',0 ; -y
GUIVideoText4 db 'EAGLE ENGINE',0 ; -y
GUIVideoTexthq3x db 'HQ3X FILTER',0
GUIVideoText5 db 'FULL SCREEN',0 ; -c
GUIVideoText5b db 'WIDE SCREEN',0 ; -c
GUIVideoText6 db 'SMALL SCREEN',0 ; -c
@@ -5241,10 +5250,10 @@ GUIGUIAboutText3 db ' ZSKNIGHT',0
GUIGUIAboutText4 db ' _DEMO_',0
GUIGUIAboutText6c db ' PAGEFAULT',0
GUIGUIAboutText5 db 'ASSISTANT CODERS : ',0
GUIGUIAboutText6 db ' PHAROS NACH',0
GUIGUIAboutText6b db ' TEUF HPSOLO',0
GUIGUIAboutText6d db ' THEODDONE33 STAINLESS',0
GUIGUIAboutText6e db ' ',0
GUIGUIAboutText6 db ' PHAROS',0
GUIGUIAboutText6b db ' TEUF',0
GUIGUIAboutText6d db ' THEODDONE33',0
GUIGUIAboutText6e db ' STAINLESS',0
%ifdef __MSDOS__
GUIGUIAboutText7 db 'DOS VERSION',0