1
0
mirror of https://github.com/DxWnd/DxWnd.reloaded synced 2024-12-30 09:25:35 +01:00

v2_02_48_src

Former-commit-id: 19f43f4c12b744296ce9f3a14cbb21b3e51b7fd9
This commit is contained in:
gho tik 2013-08-12 12:38:35 -04:00 committed by Refael ACkermann
parent b090498d29
commit fceaa16fbd
24 changed files with 386 additions and 264 deletions

View File

@ -120,6 +120,8 @@
#define ZBUFFERCLEAN 0x00000010 // Clean ZBUFFER upon (fix for "Star Wars Ep. I - Racer") #define ZBUFFERCLEAN 0x00000010 // Clean ZBUFFER upon (fix for "Star Wars Ep. I - Racer")
#define ZBUFFER0CLEAN 0x00000020 // Clean ZBUFFER upon (fix for "Star Wars Ep. I - Racer") #define ZBUFFER0CLEAN 0x00000020 // Clean ZBUFFER upon (fix for "Star Wars Ep. I - Racer")
#define ZBUFFERALWAYS 0x00000040 // Forces ZBUFFER D3DCMP_ALWAYS condition to show all planes.... #define ZBUFFERALWAYS 0x00000040 // Forces ZBUFFER D3DCMP_ALWAYS condition to show all planes....
#define DISABLEFOGGING 0x00000080 // Disable D3D fogging
#define NOPOWER2FIX 0x00000100 // Handle textures whose size is not a power of 2 (32, 64, 128 ...)
// logging Tflags DWORD: // logging Tflags DWORD:
#define OUTTRACE 0x00000001 // enables tracing to dxwnd.log in general #define OUTTRACE 0x00000001 // enables tracing to dxwnd.log in general

View File

@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1 version https://git-lfs.github.com/spec/v1
oid sha256:404c01ee20ad1832dc37c27ab836098886b2f3363181e6976a52457ecd82d59e oid sha256:57ef9c7d9946325fb6dd60e4af9dc304c495324ecae9a692cf86f91992cebbfb
size 430592 size 431616

View File

@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1 version https://git-lfs.github.com/spec/v1
oid sha256:a5c2c347ab9be31f30206cc590f69d6d24bbd4e63aca63bea0f46931ef7afcb1 oid sha256:0a4a4d772a6ec7426fd16e1891cfb4b0bc0f853cbb5a6cdcaa080f131bdd340e
size 531968 size 531968

View File

@ -281,10 +281,10 @@ module12=
opengllib12= opengllib12=
ver12=7 ver12=7
coord12=0 coord12=0
flag12=134234148 flag12=155205668
flagg12=1207959552 flagg12=1207959568
flagh12=20 flagh12=20
flagi12=36 flagi12=292
tflag12=258 tflag12=258
initx12=0 initx12=0
inity12=0 inity12=0
@ -919,17 +919,17 @@ sizx39=800
sizy39=600 sizy39=600
maxfps39=0 maxfps39=0
initts39=0 initts39=0
title40=Magic & Mayhem title40=Mageslayer
path40=D:\Games\Magic_&_Mayhem\Chaos.exe path40=D:\Games\MAGE\MAGESLAY.EXE
module40= module40=
opengllib40= opengllib40=
ver40=0 ver40=0
coord40=0 coord40=0
flag40=134217762 flag40=134217762
flagg40=1207959552 flagg40=1207959584
flagh40=20 flagh40=20
flagi40=4 flagi40=0
tflag40=0 tflag40=67
initx40=0 initx40=0
inity40=0 inity40=0
minx40=0 minx40=0
@ -942,16 +942,16 @@ sizx40=800
sizy40=600 sizy40=600
maxfps40=0 maxfps40=0
initts40=0 initts40=0
title41=Motocross Madness (DEMO) title41=Magic & Mayhem
path41=D:\Games\Motocross Madness Trial\mcm.exe path41=D:\Games\Magic_&_Mayhem\Chaos.exe
module41= module41=
opengllib41= opengllib41=
ver41=0 ver41=0
coord41=0 coord41=0
flag41=134217760 flag41=134217762
flagg41=1207959552 flagg41=1207959552
flagh41=20 flagh41=20
flagi41=0 flagi41=4
tflag41=0 tflag41=0
initx41=0 initx41=0
inity41=0 inity41=0
@ -965,16 +965,16 @@ sizx41=800
sizy41=600 sizy41=600
maxfps41=0 maxfps41=0
initts41=0 initts41=0
title42=Pandemonium 2 (GLIDE) title42=Motocross Madness (DEMO)
path42=D:\Games\Pandemonium 2\pandy.exe path42=D:\Games\Motocross Madness Trial\mcm.exe
module42= module42=
opengllib42= opengllib42=
ver42=0 ver42=0
coord42=0 coord42=0
flag42=134217762 flag42=134217760
flagg42=1207959552 flagg42=1207959552
flagh42=20 flagh42=20
flagi42=4 flagi42=0
tflag42=0 tflag42=0
initx42=0 initx42=0
inity42=0 inity42=0
@ -988,17 +988,17 @@ sizx42=800
sizy42=600 sizy42=600
maxfps42=0 maxfps42=0
initts42=0 initts42=0
title43=Praetorians title43=Pandemonium 2 (GLIDE)
path43=D:\games\Praetorians\Praetorians.exe path43=D:\Games\Pandemonium 2\pandy.exe
module43= module43=
opengllib43= opengllib43=
ver43=0 ver43=0
coord43=2 coord43=0
flag43=134217760 flag43=134217762
flagg43=1209008144 flagg43=1207959552
flagh43=22 flagh43=20
flagi43=4 flagi43=4
tflag43=2 tflag43=0
initx43=0 initx43=0
inity43=0 inity43=0
minx43=0 minx43=0
@ -1011,17 +1011,17 @@ sizx43=800
sizy43=600 sizy43=600
maxfps43=0 maxfps43=0
initts43=0 initts43=0
title44=Praetorians (DEMO) title44=Panzer Dragoon
path44=D:\Games\Praetorians Demo\Praetorians.exe path44=D:\Games\Panzer Dragoon\game\PANZERDG.EXE
module44= module44=
opengllib44= opengllib44=
ver44=0 ver44=0
coord44=0 coord44=0
flag44=134217760 flag44=134217762
flagg44=1207959552 flagg44=1207959552
flagh44=65556 flagh44=20
flagi44=4 flagi44=4
tflag44=2 tflag44=67
initx44=0 initx44=0
inity44=0 inity44=0
minx44=0 minx44=0
@ -1034,17 +1034,17 @@ sizx44=800
sizy44=600 sizy44=600
maxfps44=0 maxfps44=0
initts44=0 initts44=0
title45=Project Nomads (DEMO) title45=Praetorians
path45=D:\Games\Project Nomads Demo\bin\win32\nomads.exe path45=D:\games\Praetorians\Praetorians.exe
module45= module45=
opengllib45= opengllib45=
ver45=8 ver45=0
coord45=0 coord45=2
flag45=-1476394974 flag45=134217760
flagg45=1207959808 flagg45=1209008144
flagh45=4 flagh45=22
flagi45=0 flagi45=4
tflag45=274 tflag45=2
initx45=0 initx45=0
inity45=0 inity45=0
minx45=0 minx45=0
@ -1057,17 +1057,17 @@ sizx45=800
sizy45=600 sizy45=600
maxfps45=0 maxfps45=0
initts45=0 initts45=0
title46=Rayman 2 Demo title46=Praetorians (DEMO)
path46=D:\Games\Rayman2Demo\Rayman2Demo.exe path46=D:\Games\Praetorians Demo\Praetorians.exe
module46= module46=
opengllib46= opengllib46=
ver46=7 ver46=0
coord46=0 coord46=0
flag46=402653219 flag46=134217760
flagg46=1208025088 flagg46=1207959552
flagh46=2097172 flagh46=65556
flagi46=0 flagi46=4
tflag46=258 tflag46=2
initx46=0 initx46=0
inity46=0 inity46=0
minx46=0 minx46=0
@ -1079,16 +1079,16 @@ posy46=50
sizx46=800 sizx46=800
sizy46=600 sizy46=600
maxfps46=0 maxfps46=0
initts46=4 initts46=0
title47=Shadows of the Empire (DEMO) title47=Project Nomads (DEMO)
path47=D:\Games\Shadows of the Empire\shadows.exe path47=D:\Games\Project Nomads Demo\bin\win32\nomads.exe
module47= module47=
opengllib47= opengllib47=
ver47=0 ver47=8
coord47=2 coord47=0
flag47=134479906 flag47=-1476394974
flagg47=1207959568 flagg47=1207959808
flagh47=33554452 flagh47=4
flagi47=0 flagi47=0
tflag47=274 tflag47=274
initx47=0 initx47=0
@ -1103,17 +1103,17 @@ sizx47=800
sizy47=600 sizy47=600
maxfps47=0 maxfps47=0
initts47=0 initts47=0
title48=StarCraft title48=Rayman 2 Demo
path48=D:\Games\Starcraft\StarCraft.exe path48=D:\Games\Rayman2Demo\Rayman2Demo.exe
module48= module48=
opengllib48= opengllib48=
ver48=0 ver48=7
coord48=0 coord48=0
flag48=134217762 flag48=402653219
flagg48=134283264 flagg48=1208025088
flagh48=20 flagh48=2097172
flagi48=8 flagi48=0
tflag48=64 tflag48=258
initx48=0 initx48=0
inity48=0 inity48=0
minx48=0 minx48=0
@ -1125,18 +1125,18 @@ posy48=50
sizx48=800 sizx48=800
sizy48=600 sizy48=600
maxfps48=0 maxfps48=0
initts48=0 initts48=4
title49=Tomb Raider 4 (DEMO) title49=Shadows of the Empire (DEMO)
path49=D:\Games\Tomb Raider - The Last Revelation (Demo)\tomb4.exe path49=D:\Games\Shadows of the Empire\shadows.exe
module49= module49=
opengllib49= opengllib49=
ver49=7 ver49=0
coord49=0 coord49=2
flag49=134217760 flag49=134479906
flagg49=1207959552 flagg49=1207959568
flagh49=20 flagh49=33554452
flagi49=0 flagi49=0
tflag49=258 tflag49=274
initx49=0 initx49=0
inity49=0 inity49=0
minx49=0 minx49=0
@ -1149,17 +1149,17 @@ sizx49=800
sizy49=600 sizy49=600
maxfps49=0 maxfps49=0
initts49=0 initts49=0
title50=Tomb Raider II title50=Star Wars Episode I Racer
path50=D:\Games\Tomb Raider II\Tomb2.exe path50=D:\Games\Star Wars Episode 1 racer\SWEP1RCR.EXE
module50= module50=
opengllib50= opengllib50=
ver50=0 ver50=0
coord50=0 coord50=0
flag50=671088674 flag50=679493669
flagg50=1207959552 flagg50=1210056720
flagh50=20 flagh50=8212
flagi50=0 flagi50=20
tflag50=0 tflag50=67
initx50=0 initx50=0
inity50=0 inity50=0
minx50=0 minx50=0
@ -1172,20 +1172,20 @@ sizx50=800
sizy50=600 sizy50=600
maxfps50=0 maxfps50=0
initts50=0 initts50=0
title51=Tomb Raider II Gold (DEMO) title51=StarCraft
module51= module51=
opengllib51= opengllib51=
title52=Tomb Raider III title52=Tomb Raider 4 (DEMO)
module52= module52=
opengllib52= opengllib52=
path51=D:\Games\Tomb Raider II Gold (Demo)\Tomb2.exe path51=D:\Games\Starcraft\StarCraft.exe
ver51=0 ver51=0
coord51=2 coord51=0
flag51=671088674 flag51=134217762
flagg51=1224736784 flagg51=134283264
flagh51=20 flagh51=20
flagi51=0 flagi51=8
tflag51=258 tflag51=64
initx51=0 initx51=0
inity51=0 inity51=0
minx51=0 minx51=0
@ -1198,14 +1198,14 @@ sizx51=800
sizy51=600 sizy51=600
maxfps51=0 maxfps51=0
initts51=0 initts51=0
path52=D:\Games\Tomb Raider III\tomb3.exe path52=D:\Games\Tomb Raider - The Last Revelation (Demo)\tomb4.exe
ver52=0 ver52=7
coord52=2 coord52=0
flag52=134217760 flag52=134217760
flagg52=1241514000 flagg52=1207959552
flagh52=20 flagh52=20
flagi52=0 flagi52=0
tflag52=322 tflag52=258
initx52=0 initx52=0
inity52=0 inity52=0
minx52=0 minx52=0
@ -1218,14 +1218,14 @@ sizx52=800
sizy52=600 sizy52=600
maxfps52=0 maxfps52=0
initts52=0 initts52=0
title53=Virtua Fighter 2 (DEMO) title53=Tomb Raider II
path53=D:\Games\vf2_demo\VF2DEMO.EXE path53=D:\Games\Tomb Raider II\Tomb2.exe
module53= module53=
opengllib53= opengllib53=
ver53=0 ver53=0
coord53=0 coord53=0
flag53=939524131 flag53=671088674
flagg53=1207959664 flagg53=1207959552
flagh53=20 flagh53=20
flagi53=0 flagi53=0
tflag53=0 tflag53=0
@ -1241,15 +1241,15 @@ sizx53=800
sizy53=600 sizy53=600
maxfps53=0 maxfps53=0
initts53=0 initts53=0
title54=Virtua Fighter PC title54=Tomb Raider II Gold (DEMO)
path54=D:\Games\Virtua Fighter\VFPC.EXE path54=D:\Games\Tomb Raider II Gold (Demo)\Tomb2.exe
module54= module54=
opengllib54= opengllib54=
ver54=0 ver54=0
coord54=0 coord54=2
flag54=402653218 flag54=671088674
flagg54=1224736784 flagg54=1224736784
flagh54=33562644 flagh54=20
flagi54=0 flagi54=0
tflag54=258 tflag54=258
initx54=0 initx54=0
@ -1264,17 +1264,17 @@ sizx54=800
sizy54=600 sizy54=600
maxfps54=0 maxfps54=0
initts54=0 initts54=0
title55=Warcraft 2 Battlenet Ed title55=Tomb Raider III
path55=D:\Games\Warcraft 2 Battlenet Ed\Warcraft II BNE.exe path55=D:\Games\Tomb Raider III\tomb3.exe
module55= module55=
opengllib55= opengllib55=
ver55=0 ver55=0
coord55=0 coord55=2
flag55=134217762 flag55=134217760
flagg55=1210122240 flagg55=1241514000
flagh55=148 flagh55=20
flagi55=12 flagi55=0
tflag55=0 tflag55=322
initx55=0 initx55=0
inity55=0 inity55=0
minx55=0 minx55=0
@ -1287,17 +1287,17 @@ sizx55=800
sizy55=600 sizy55=600
maxfps55=0 maxfps55=0
initts55=0 initts55=0
title56=Wargasm title56=Virtua Fighter 2 (DEMO)
path56=D:\Games\Wargasm\tank.exe path56=D:\Games\vf2_demo\VF2DEMO.EXE
module56= module56=
opengllib56= opengllib56=
ver56=0 ver56=0
coord56=2 coord56=0
flag56=671088672 flag56=939524131
flagg56=1207959696 flagg56=1207959664
flagh56=65556 flagh56=20
flagi56=0 flagi56=0
tflag56=3 tflag56=0
initx56=0 initx56=0
inity56=0 inity56=0
minx56=0 minx56=0
@ -1310,15 +1310,15 @@ sizx56=800
sizy56=600 sizy56=600
maxfps56=0 maxfps56=0
initts56=0 initts56=0
title57=Warlords Battlecry II (DEMO) title57=Virtua Fighter PC
path57=D:\Games\Warlords Battlecry II Demo\Battlecry II Demo.exe path57=D:\Games\Virtua Fighter\VFPC.EXE
module57= module57=
opengllib57= opengllib57=
ver57=0 ver57=0
coord57=2 coord57=0
flag57=134217762 flag57=402653218
flagg57=1207959568 flagg57=1224736784
flagh57=22 flagh57=33562644
flagi57=0 flagi57=0
tflag57=258 tflag57=258
initx57=0 initx57=0
@ -1333,17 +1333,17 @@ sizx57=800
sizy57=600 sizy57=600
maxfps57=0 maxfps57=0
initts57=0 initts57=0
title58=Whiteout title58=Warcraft 2 Battlenet Ed
path58=D:\Games\Whiteout\Whiteout.exe path58=D:\Games\Warcraft 2 Battlenet Ed\Warcraft II BNE.exe
module58= module58=
opengllib58= opengllib58=
ver58=0 ver58=0
coord58=0 coord58=0
flag58=402653217 flag58=134217762
flagg58=1207959552 flagg58=1210122240
flagh58=20 flagh58=148
flagi58=0 flagi58=12
tflag58=66 tflag58=0
initx58=0 initx58=0
inity58=0 inity58=0
minx58=0 minx58=0
@ -1352,21 +1352,21 @@ maxx58=0
maxy58=0 maxy58=0
posx58=50 posx58=50
posy58=50 posy58=50
sizx58=640 sizx58=800
sizy58=480 sizy58=600
maxfps58=0 maxfps58=0
initts58=0 initts58=0
title59=Wildfire title59=Wargasm
path59=D:\Games\Wildfire\Wildfire.exe path59=D:\Games\Wargasm\tank.exe
module59= module59=
opengllib59= opengllib59=
ver59=0 ver59=0
coord59=0 coord59=2
flag59=-1476392958 flag59=671088672
flagg59=1210122240 flagg59=1207959696
flagh59=20 flagh59=65556
flagi59=12 flagi59=0
tflag59=0 tflag59=3
initx59=0 initx59=0
inity59=0 inity59=0
minx59=0 minx59=0
@ -1379,16 +1379,16 @@ sizx59=800
sizy59=600 sizy59=600
maxfps59=0 maxfps59=0
initts59=0 initts59=0
title60=Worms Pinball title60=Warlords Battlecry II (DEMO)
path60=D:\Games\Worms Pinball\WPIB.exe path60=D:\Games\Warlords Battlecry II Demo\Battlecry II Demo.exe
module60= module60=
opengllib60= opengllib60=
ver60=0 ver60=0
coord60=2 coord60=2
flag60=679477282 flag60=134217762
flagg60=1744830480 flagg60=1207959568
flagh60=20 flagh60=22
flagi60=4 flagi60=0
tflag60=258 tflag60=258
initx60=0 initx60=0
inity60=0 inity60=0
@ -1402,17 +1402,17 @@ sizx60=800
sizy60=600 sizy60=600
maxfps60=0 maxfps60=0
initts60=0 initts60=0
title61=Zanzarah title61=Whiteout
path61=D:\Games\Zanzarah\System\zanthp.exe path61=D:\Games\Whiteout\Whiteout.exe
module61= module61=
opengllib61= opengllib61=
ver61=0 ver61=0
coord61=0 coord61=0
flag61=679477280 flag61=402653217
flagg61=1207959552 flagg61=1207959552
flagh61=20 flagh61=20
flagi61=0 flagi61=0
tflag61=0 tflag61=66
initx61=0 initx61=0
inity61=0 inity61=0
minx61=0 minx61=0
@ -1421,21 +1421,21 @@ maxx61=0
maxy61=0 maxy61=0
posx61=50 posx61=50
posy61=50 posy61=50
sizx61=800 sizx61=640
sizy61=600 sizy61=480
maxfps61=0 maxfps61=0
initts61=0 initts61=0
title62=Zax the Alien Hunter (DEMO) title62=Wildfire
path62=D:\Games\ZaxDemo\Zax.exe path62=D:\Games\Wildfire\Wildfire.exe
module62= module62=
opengllib62= opengllib62=
ver62=0 ver62=0
coord62=2 coord62=0
flag62=-2011168734 flag62=-1476392958
flagg62=1209008144 flagg62=1210122240
flagh62=20 flagh62=20
flagi62=0 flagi62=12
tflag62=258 tflag62=0
initx62=0 initx62=0
inity62=0 inity62=0
minx62=0 minx62=0
@ -1448,17 +1448,17 @@ sizx62=800
sizy62=600 sizy62=600
maxfps62=0 maxfps62=0
initts62=0 initts62=0
title63=ZPC Zero Population Count title63=Worms Pinball
path63=D:\Games\ZPC\ZPC.EXE path63=D:\Games\Worms Pinball\WPIB.exe
module63= module63=
opengllib63= opengllib63=
ver63=0 ver63=0
coord63=0 coord63=2
flag63=134217762 flag63=679477282
flagg63=1207959552 flagg63=1744830480
flagh63=20 flagh63=20
flagi63=4 flagi63=4
tflag63=0 tflag63=258
initx63=0 initx63=0
inity63=0 inity63=0
minx63=0 minx63=0
@ -1471,17 +1471,17 @@ sizx63=800
sizy63=600 sizy63=600
maxfps63=0 maxfps63=0
initts63=0 initts63=0
title64=Star Wars Episode I Racer title64=Zanzarah
path64=D:\Games\Star Wars Episode 1 racer\SWEP1RCR.EXE path64=D:\Games\Zanzarah\System\zanthp.exe
module64= module64=
opengllib64= opengllib64=
ver64=0 ver64=0
coord64=0 coord64=0
flag64=679493669 flag64=679477280
flagg64=1210056720 flagg64=1207959552
flagh64=8212 flagh64=20
flagi64=20 flagi64=0
tflag64=67 tflag64=0
initx64=0 initx64=0
inity64=0 inity64=0
minx64=0 minx64=0
@ -1494,17 +1494,17 @@ sizx64=800
sizy64=600 sizy64=600
maxfps64=0 maxfps64=0
initts64=0 initts64=0
title65=Mageslayer title65=Zax the Alien Hunter (DEMO)
path65=D:\Games\MAGE\MAGESLAY.EXE path65=D:\Games\ZaxDemo\Zax.exe
module65= module65=
opengllib65= opengllib65=
ver65=0 ver65=0
coord65=0 coord65=2
flag65=134217762 flag65=-2011168734
flagg65=1207959552 flagg65=1209008144
flagh65=20 flagh65=20
flagi65=0 flagi65=0
tflag65=67 tflag65=258
initx65=0 initx65=0
inity65=0 inity65=0
minx65=0 minx65=0
@ -1517,8 +1517,31 @@ sizx65=800
sizy65=600 sizy65=600
maxfps65=0 maxfps65=0
initts65=0 initts65=0
title66=ZPC Zero Population Count
path66=D:\Games\ZPC\ZPC.EXE
module66=
opengllib66=
ver66=0
coord66=0
flag66=134217762
flagg66=1207959552
flagh66=20
flagi66=4
tflag66=0
initx66=0
inity66=0
minx66=0
miny66=0
maxx66=0
maxy66=0
posx66=50
posy66=50
sizx66=800
sizy66=600
maxfps66=0
initts66=0
[window] [window]
posx=1056 posx=953
posy=200 posy=245
sizx=638 sizx=638
sizy=670 sizy=670

View File

@ -5,10 +5,10 @@ module0=
opengllib0= opengllib0=
ver0=7 ver0=7
coord0=0 coord0=0
flag0=134234148 flag0=155205668
flagg0=1207959552 flagg0=1207959568
flagh0=20 flagh0=20
flagi0=36 flagi0=292
tflag0=258 tflag0=258
initx0=0 initx0=0
inity0=0 inity0=0

View File

@ -0,0 +1,24 @@
[target]
title0=Panzer Dragoon
path0=D:\Games\Panzer Dragoon\game\PANZERDG.EXE
module0=
opengllib0=
ver0=0
coord0=0
flag0=134217762
flagg0=1207959552
flagh0=20
flagi0=4
tflag0=67
initx0=0
inity0=0
minx0=0
miny0=0
maxx0=0
maxy0=0
posx0=50
posy0=50
sizx0=800
sizy0=600
maxfps0=0
initts0=0

View File

@ -319,4 +319,8 @@ Configuration tabs reorganization: now some tabs have merged making it easier to
core: core:
improved d3d wrapping and sdded ZBUFFER cleanup flags to fix some d3d games. In particular: improved d3d wrapping and sdded ZBUFFER cleanup flags to fix some d3d games. In particular:
Clean ZBUFFER @1.0 fix: to fix "Star Wars Episode I Racer" Clean ZBUFFER @1.0 fix: to fix "Star Wars Episode I Racer"
Clean ZBUFFER @0.0 fix: to fix "Crimson Skies" black blocks bug on ATI cards Clean ZBUFFER @0.0 fix: to fix "Crimson Skies" black blocks bug on ATI cards
v2.02.48
New options: "Disable fogging", "Textures not power of 2 fix"
A few fix to prevent game crashes

View File

@ -3609,7 +3609,7 @@ HRESULT WINAPI extUnlockDir(int dxversion, Unlock4_Type pUnlock, LPDIRECTDRAWSUR
res=(*pUnlock)(lpdds, lprect); res=(*pUnlock)(lpdds, lprect);
if (res) OutTraceE("Unlock ERROR res=%x(%s) at %d\n",res, ExplainDDError(res), __LINE__); if (res) OutTraceE("Unlock ERROR res=%x(%s) at %d\n",res, ExplainDDError(res), __LINE__);
if (IsPrim && res==DD_OK) sBlt("Unlock", lpdds, NULL, lpdds, NULL, NULL, 0, FALSE); if (IsPrim && res==DD_OK) sBlt("Unlock", lpdds, NULL, lpdds, NULL, NULL, 0, FALSE);
if(dxw.dwFlags1 & SUPPRESSDXERRORS) res=0; if(dxw.dwFlags1 & SUPPRESSDXERRORS) res=DD_OK;
return res; return res;
} }

View File

@ -66,8 +66,8 @@ static char *Flag3Names[32]={
static char *Flag4Names[32]={ static char *Flag4Names[32]={
"NOALPHACHANNEL", "SUPPRESSCHILD", "FIXREFCOUNTER", "SHOWTIMESTRETCH", "NOALPHACHANNEL", "SUPPRESSCHILD", "FIXREFCOUNTER", "SHOWTIMESTRETCH",
"", "", "", "", "ZBUFFERCLEAN", "ZBUFFER0CLEAN", "ZBUFFERALWAYS", "DISABLEFOGGING",
"", "", "", "", "NOPOWER2FIX", "", "", "",
"", "", "", "", "", "", "", "",
"", "", "", "", "", "", "", "",
"", "", "", "", "", "", "", "",

View File

@ -28,6 +28,7 @@ dxwCore::dxwCore()
//IsGDIPalette = FALSE; //IsGDIPalette = FALSE;
memset(PrimSurfaces, 0, sizeof(PrimSurfaces)); memset(PrimSurfaces, 0, sizeof(PrimSurfaces));
ResetEmulatedDC(); ResetEmulatedDC();
MustShowOverlay=FALSE;
} }
dxwCore::~dxwCore() dxwCore::~dxwCore()
@ -73,6 +74,7 @@ void dxwCore::InitTarget(TARGETMAP *target)
if(TimeShift > 8) TimeShift = 8; if(TimeShift > 8) TimeShift = 8;
FakeVersionId = target->FakeVersionId; FakeVersionId = target->FakeVersionId;
Coordinates = target->coordinates; Coordinates = target->coordinates;
MustShowOverlay=((dwFlags2 & SHOWFPSOVERLAY) || (dwFlags4 & SHOWTIMESTRETCH));
} }
/* ------------------------------------------------------------------ */ /* ------------------------------------------------------------------ */
@ -919,35 +921,39 @@ void dxwCore::GetSystemTime(LPSYSTEMTIME lpSystemTime)
void dxwCore::ShowOverlay() void dxwCore::ShowOverlay()
{ {
this->ShowOverlay(GetDC(hWnd)); if (MustShowOverlay) this->ShowOverlay(GetDC(hWnd));
} }
void dxwCore::ShowOverlay(LPDIRECTDRAWSURFACE lpdds) void dxwCore::ShowOverlay(LPDIRECTDRAWSURFACE lpdds)
{ {
HDC hdc; // the working dc HDC hdc; // the working dc
if (FAILED(lpdds->GetDC(&hdc))) return; if (MustShowOverlay) {
this->ShowOverlay(hdc); if(!lpdds) return;
lpdds->ReleaseDC(hdc); if (FAILED(lpdds->GetDC(&hdc))) return;
this->ShowOverlay(hdc);
lpdds->ReleaseDC(hdc);
}
} }
void dxwCore::ShowOverlay(HDC hdc) void dxwCore::ShowOverlay(HDC hdc)
{ {
if(!hdc) return;
if (dwFlags2 & SHOWFPSOVERLAY) ShowFPS(hdc); if (dwFlags2 & SHOWFPSOVERLAY) ShowFPS(hdc);
if (dwFlags4 & SHOWTIMESTRETCH) ShowTimeStretching(hdc); if (dwFlags4 & SHOWTIMESTRETCH) ShowTimeStretching(hdc);
} }
void dxwCore::ShowFPS() //void dxwCore::ShowFPS()
{ //{
this->ShowFPS(GetDC(hWnd)); // this->ShowFPS(GetDC(hWnd));
} //}
//
void dxwCore::ShowFPS(LPDIRECTDRAWSURFACE lpdds) //void dxwCore::ShowFPS(LPDIRECTDRAWSURFACE lpdds)
{ //{
HDC hdc; // the working dc // HDC hdc; // the working dc
if (FAILED(lpdds->GetDC(&hdc))) return; // if (FAILED(lpdds->GetDC(&hdc))) return;
this->ShowFPS(hdc); // this->ShowFPS(hdc);
lpdds->ReleaseDC(hdc); // lpdds->ReleaseDC(hdc);
} //}
void dxwCore::ShowFPS(HDC xdc) void dxwCore::ShowFPS(HDC xdc)
{ {
@ -978,25 +984,25 @@ void dxwCore::ShowFPS(HDC xdc)
TextOut(xdc, x, y, sBuf, strlen(sBuf)); TextOut(xdc, x, y, sBuf, strlen(sBuf));
} }
void dxwCore::ShowTimeStretching() //void dxwCore::ShowTimeStretching()
{ //{
HDC hdc; // HDC hdc;
hdc=GetDC(hWnd); // hdc=GetDC(hWnd);
if(hdc)this->ShowTimeStretching(hdc); // if(hdc)this->ShowTimeStretching(hdc);
} //}
//
void dxwCore::ShowTimeStretching(LPDIRECTDRAWSURFACE lpdds) //void dxwCore::ShowTimeStretching(LPDIRECTDRAWSURFACE lpdds)
{ //{
HDC hdc; // the working dc // HDC hdc; // the working dc
__try { // __try {
if (FAILED(lpdds->GetDC(&hdc))) return; // if (FAILED(lpdds->GetDC(&hdc))) return;
} // }
__except(EXCEPTION_EXECUTE_HANDLER){ // __except(EXCEPTION_EXECUTE_HANDLER){
return; // return;
} // }
if(hdc)this->ShowTimeStretching(hdc); // if(hdc)this->ShowTimeStretching(hdc);
lpdds->ReleaseDC(hdc); // lpdds->ReleaseDC(hdc);
} //}
void dxwCore::ShowTimeStretching(HDC xdc) void dxwCore::ShowTimeStretching(HDC xdc)
{ {

View File

@ -65,12 +65,6 @@ public: // methods
void GetSystemTimeAsFileTime(LPFILETIME lpSystemTimeAsFileTime); void GetSystemTimeAsFileTime(LPFILETIME lpSystemTimeAsFileTime);
DWORD StretchTime(DWORD); DWORD StretchTime(DWORD);
DWORD StretchCounter(DWORD); DWORD StretchCounter(DWORD);
void ShowFPS(LPDIRECTDRAWSURFACE);
void ShowTimeStretching(LPDIRECTDRAWSURFACE);
void ShowFPS(void);
void ShowTimeStretching(void);
void ShowFPS(HDC);
void ShowTimeStretching(HDC);
void ShowOverlay(); void ShowOverlay();
void ShowOverlay(HDC); void ShowOverlay(HDC);
void ShowOverlay(LPDIRECTDRAWSURFACE); void ShowOverlay(LPDIRECTDRAWSURFACE);
@ -112,8 +106,6 @@ public: // simple data variables
short iPosY; short iPosY;
short iSizX; short iSizX;
short iSizY; short iSizY;
//BOOL IsWithinDDraw; // flag to avoid double intervention at ddraw & GDI level
//BOOL IsGDIPalette;
char *CustomOpenGLLib; char *CustomOpenGLLib;
WORD palVersion; WORD palVersion;
WORD palNumEntries; WORD palNumEntries;
@ -135,7 +127,9 @@ protected:
private: private:
void UnmarkPrimarySurface(LPDIRECTDRAWSURFACE); void UnmarkPrimarySurface(LPDIRECTDRAWSURFACE);
void UnmarkBackBufferSurface(LPDIRECTDRAWSURFACE); void UnmarkBackBufferSurface(LPDIRECTDRAWSURFACE);
BOOL MustShowOverlay;
void ShowFPS(HDC);
void ShowTimeStretching(HDC);
}; };
extern dxwCore dxw; extern dxwCore dxw;

View File

@ -24,7 +24,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#include "dxwnd.h" #include "dxwnd.h"
#include "dxwcore.hpp" #include "dxwcore.hpp"
#define VERSION "2.02.47" #define VERSION "2.02.48"
#define DDTHREADLOCK 1 #define DDTHREADLOCK 1

Binary file not shown.

View File

@ -42,6 +42,7 @@ typedef HRESULT (WINAPI *D3DGetCaps_Type)(void *, LPD3DDEVICEDESC ,LPD3DDEVICEDE
typedef HRESULT (WINAPI *SetRenderState3_Type)(void *, D3DRENDERSTATETYPE, DWORD); typedef HRESULT (WINAPI *SetRenderState3_Type)(void *, D3DRENDERSTATETYPE, DWORD);
typedef HRESULT (WINAPI *Scene3_Type)(void *); typedef HRESULT (WINAPI *Scene3_Type)(void *);
typedef HRESULT (WINAPI *GetCaps3_Type)(void *, LPD3DDEVICEDESC, LPD3DDEVICEDESC);
Initialize_Type pInitialize = NULL; Initialize_Type pInitialize = NULL;
@ -67,6 +68,8 @@ Scene3_Type pEndScene1 = NULL;
Scene3_Type pEndScene2 = NULL; Scene3_Type pEndScene2 = NULL;
Scene3_Type pEndScene3 = NULL; Scene3_Type pEndScene3 = NULL;
GetCaps3_Type pGetCaps3 = NULL;
D3DInitialize_Type pD3DInitialize = NULL; D3DInitialize_Type pD3DInitialize = NULL;
D3DGetCaps_Type pD3DGetCaps = NULL; D3DGetCaps_Type pD3DGetCaps = NULL;
@ -95,6 +98,7 @@ HRESULT WINAPI extEndScene2(void *);
HRESULT WINAPI extSetRenderState3(void *, D3DRENDERSTATETYPE, DWORD); HRESULT WINAPI extSetRenderState3(void *, D3DRENDERSTATETYPE, DWORD);
HRESULT WINAPI extBeginScene3(void *); HRESULT WINAPI extBeginScene3(void *);
HRESULT WINAPI extEndScene3(void *); HRESULT WINAPI extEndScene3(void *);
HRESULT WINAPI extGetCaps3(void *, LPD3DDEVICEDESC, LPD3DDEVICEDESC);
extern char *ExplainDDError(DWORD); extern char *ExplainDDError(DWORD);
@ -215,23 +219,28 @@ void HookDirect3DDevice(void **lpd3ddev, int dxversion)
switch(dxversion){ switch(dxversion){
case 1: case 1:
//SetHook((void *)(**(DWORD **)lpd3ddev + 16), extGetCaps1, (void **)&pGetCaps1, "GetCaps(1)");
SetHook((void *)(**(DWORD **)lpd3ddev + 76), extBeginScene1, (void **)&pBeginScene1, "BeginScene(1)"); SetHook((void *)(**(DWORD **)lpd3ddev + 76), extBeginScene1, (void **)&pBeginScene1, "BeginScene(1)");
SetHook((void *)(**(DWORD **)lpd3ddev + 80), extEndScene1, (void **)&pEndScene1, "EndScene(1)"); SetHook((void *)(**(DWORD **)lpd3ddev + 80), extEndScene1, (void **)&pEndScene1, "EndScene(1)");
break; break;
case 2: case 2:
//SetHook((void *)(**(DWORD **)lpd3ddev + 12), extGetCaps2, (void **)&pGetCaps2, "GetCaps(2)");
SetHook((void *)(**(DWORD **)lpd3ddev + 40), extBeginScene2, (void **)&pBeginScene2, "BeginScene(2)"); SetHook((void *)(**(DWORD **)lpd3ddev + 40), extBeginScene2, (void **)&pBeginScene2, "BeginScene(2)");
SetHook((void *)(**(DWORD **)lpd3ddev + 44), extEndScene2, (void **)&pEndScene2, "EndScene(2)"); SetHook((void *)(**(DWORD **)lpd3ddev + 44), extEndScene2, (void **)&pEndScene2, "EndScene(2)");
SetHook((void *)(**(DWORD **)lpd3ddev + 92), extSetRenderState2, (void **)&pSetRenderState2, "SetRenderState(2)"); SetHook((void *)(**(DWORD **)lpd3ddev + 92), extSetRenderState2, (void **)&pSetRenderState2, "SetRenderState(2)");
if(dxw.dwFlags2 & WIREFRAME){ if(pSetRenderState2){
(*pSetRenderState2)(*lpd3ddev, D3DRENDERSTATE_FILLMODE, D3DFILL_WIREFRAME); if(dxw.dwFlags2 & WIREFRAME)(*pSetRenderState2)(*lpd3ddev, D3DRENDERSTATE_FILLMODE, D3DFILL_WIREFRAME);
if(dxw.dwFlags4 & DISABLEFOGGING) (*pSetRenderState2)(*lpd3ddev, D3DRENDERSTATE_FOGENABLE, FALSE);
} }
break; break;
case 3: case 3:
SetHook((void *)(**(DWORD **)lpd3ddev + 12), extGetCaps3, (void **)&pGetCaps3, "GetCaps(3)");
SetHook((void *)(**(DWORD **)lpd3ddev + 36), extBeginScene3, (void **)&pBeginScene3, "BeginScene(3)"); SetHook((void *)(**(DWORD **)lpd3ddev + 36), extBeginScene3, (void **)&pBeginScene3, "BeginScene(3)");
SetHook((void *)(**(DWORD **)lpd3ddev + 40), extEndScene3, (void **)&pEndScene3, "EndScene(3)"); SetHook((void *)(**(DWORD **)lpd3ddev + 40), extEndScene3, (void **)&pEndScene3, "EndScene(3)");
SetHook((void *)(**(DWORD **)lpd3ddev + 88), extSetRenderState3, (void **)&pSetRenderState3, "SetRenderState(3)"); SetHook((void *)(**(DWORD **)lpd3ddev + 88), extSetRenderState3, (void **)&pSetRenderState3, "SetRenderState(3)");
if(dxw.dwFlags2 & WIREFRAME){ if(pSetRenderState3){
(*pSetRenderState3)(*lpd3ddev, D3DRENDERSTATE_FILLMODE, D3DFILL_WIREFRAME); if(dxw.dwFlags2 & WIREFRAME)(*pSetRenderState3)(*lpd3ddev, D3DRENDERSTATE_FILLMODE, D3DFILL_WIREFRAME);
if(dxw.dwFlags4 & DISABLEFOGGING) (*pSetRenderState3)(*lpd3ddev, D3DRENDERSTATE_FOGENABLE, FALSE);
} }
break; break;
} }
@ -347,7 +356,19 @@ HRESULT WINAPI extDeviceProxy(GUID FAR *lpGuid, LPSTR lpDeviceDescription, LPSTR
OutTraceD("EnumDevices: CALLBACK GUID=%x(%s) DeviceDescription=\"%s\", DeviceName=\"%s\", arg=%x\n", lpGuid->Data1, ExplainGUID(lpGuid), lpDeviceDescription, lpDeviceName, ((CallbackArg *)arg)->arg); OutTraceD("EnumDevices: CALLBACK GUID=%x(%s) DeviceDescription=\"%s\", DeviceName=\"%s\", arg=%x\n", lpGuid->Data1, ExplainGUID(lpGuid), lpDeviceDescription, lpDeviceName, ((CallbackArg *)arg)->arg);
DumpD3DDevideDesc(lpd3ddd1, "HWDEV"); DumpD3DDevideDesc(lpd3ddd1, "HWDEV");
DumpD3DDevideDesc(lpd3ddd2, "SWDEV"); DumpD3DDevideDesc(lpd3ddd2, "SWDEV");
res = (*(((CallbackArg *)arg)->cb))(lpGuid, lpDeviceDescription, lpDeviceName, lpd3ddd1, lpd3ddd2, ((CallbackArg *)arg)->arg); if(dxw.dwFlags4 & NOPOWER2FIX){
D3DDEVICEDESC lpd3ddd1fix, lpd3ddd2fix;
if(lpd3ddd1) memcpy(&lpd3ddd1fix, lpd3ddd1, sizeof(D3DDEVICEDESC));
if(lpd3ddd2) memcpy(&lpd3ddd2fix, lpd3ddd2, sizeof(D3DDEVICEDESC));
lpd3ddd1fix.dpcLineCaps.dwTextureCaps|=D3DPTEXTURECAPS_NONPOW2CONDITIONAL|D3DPTEXTURECAPS_POW2;
lpd3ddd1fix.dpcTriCaps.dwTextureCaps|=D3DPTEXTURECAPS_NONPOW2CONDITIONAL|D3DPTEXTURECAPS_POW2;
lpd3ddd2fix.dpcLineCaps.dwTextureCaps|=D3DPTEXTURECAPS_NONPOW2CONDITIONAL|D3DPTEXTURECAPS_POW2;
lpd3ddd2fix.dpcTriCaps.dwTextureCaps|=D3DPTEXTURECAPS_NONPOW2CONDITIONAL|D3DPTEXTURECAPS_POW2;
res = (*(((CallbackArg *)arg)->cb))(lpGuid, lpDeviceDescription, lpDeviceName, lpd3ddd1?&lpd3ddd1fix:NULL, lpd3ddd2?&lpd3ddd2fix:NULL, ((CallbackArg *)arg)->arg);
}
else {
res = (*(((CallbackArg *)arg)->cb))(lpGuid, lpDeviceDescription, lpDeviceName, lpd3ddd1, lpd3ddd2, ((CallbackArg *)arg)->arg);
}
OutTraceD("EnumDevices: CALLBACK ret=%x\n", res); OutTraceD("EnumDevices: CALLBACK ret=%x\n", res);
return res; return res;
} }
@ -595,6 +616,10 @@ HRESULT WINAPI extSetRenderState3(void *d3dd, D3DRENDERSTATETYPE State, DWORD Va
Value = D3DFILL_WIREFRAME; Value = D3DFILL_WIREFRAME;
OutTraceD("SetRenderState: FIXED State=FILLMODE Value=D3DFILL_WIREFRAME\n"); OutTraceD("SetRenderState: FIXED State=FILLMODE Value=D3DFILL_WIREFRAME\n");
} }
if((dxw.dwFlags4 & DISABLEFOGGING) && (State == D3DRENDERSTATE_FOGENABLE)){
OutTraceD("SetRenderState: FIXED State=FOGENABLE Value=FALSE\n");
Value = FALSE;
}
res=(*pSetRenderState3)(d3dd, State, Value); res=(*pSetRenderState3)(d3dd, State, Value);
if(res) OutTraceE("SetRenderState(3): res=%x(%s)\n", res, ExplainDDError(res)); if(res) OutTraceE("SetRenderState(3): res=%x(%s)\n", res, ExplainDDError(res));
return res; return res;
@ -614,18 +639,21 @@ HRESULT WINAPI extBeginScene2(void *d3dd)
HRESULT res; HRESULT res;
OutTraceD("BeginScene(2): d3dd=%x\n", d3dd); OutTraceD("BeginScene(2): d3dd=%x\n", d3dd);
if(dxw.dwFlags4 & ZBUFFERCLEAN){ if(dxw.dwFlags4 & ZBUFFERCLEAN){
HRESULT res2;
LPDIRECT3DVIEWPORT2 vp; LPDIRECT3DVIEWPORT2 vp;
D3DVIEWPORT vpd; D3DVIEWPORT vpd;
((LPDIRECT3DDEVICE2)d3dd)->GetCurrentViewport(&vp); res2=((LPDIRECT3DDEVICE2)d3dd)->GetCurrentViewport(&vp);
D3DRECT d3dRect; if(!res2){
vpd.dwSize=sizeof(D3DVIEWPORT); D3DRECT d3dRect;
vp->GetViewport(&vpd); vpd.dwSize=sizeof(D3DVIEWPORT);
d3dRect.x1 = vpd.dwX; vp->GetViewport(&vpd);
d3dRect.y1 = vpd.dwY; d3dRect.x1 = vpd.dwX;
d3dRect.x2 = vpd.dwX + vpd.dwWidth; d3dRect.y1 = vpd.dwY;
d3dRect.y2 = vpd.dwY + vpd.dwHeight; d3dRect.x2 = vpd.dwX + vpd.dwWidth;
OutTraceD("d3dRect=(%d,%d)-(%d,%d)\n", d3dRect.x1, d3dRect.y1, d3dRect.x2, d3dRect.y2); d3dRect.y2 = vpd.dwY + vpd.dwHeight;
vp->Clear(1, &d3dRect, D3DCLEAR_ZBUFFER); OutTraceD("d3dRect=(%d,%d)-(%d,%d)\n", d3dRect.x1, d3dRect.y1, d3dRect.x2, d3dRect.y2);
vp->Clear(1, &d3dRect, D3DCLEAR_ZBUFFER);
}
} }
res=(*pBeginScene2)(d3dd); res=(*pBeginScene2)(d3dd);
if(res) OutTraceE("BeginScene(2): res=%x(%s)\n", res, ExplainDDError(res)); if(res) OutTraceE("BeginScene(2): res=%x(%s)\n", res, ExplainDDError(res));
@ -637,19 +665,22 @@ HRESULT WINAPI extBeginScene3(void *d3dd)
HRESULT res; HRESULT res;
OutTraceD("BeginScene(3): d3dd=%x\n", d3dd); OutTraceD("BeginScene(3): d3dd=%x\n", d3dd);
if(dxw.dwFlags4 & (ZBUFFERCLEAN|ZBUFFER0CLEAN)){ if(dxw.dwFlags4 & (ZBUFFERCLEAN|ZBUFFER0CLEAN)){
HRESULT res2;
LPDIRECT3DVIEWPORT3 vp; LPDIRECT3DVIEWPORT3 vp;
D3DVIEWPORT vpd; D3DVIEWPORT vpd;
((LPDIRECT3DDEVICE3)d3dd)->GetCurrentViewport(&vp); res2=((LPDIRECT3DDEVICE3)d3dd)->GetCurrentViewport(&vp);
D3DRECT d3dRect; if(!res2){
vpd.dwSize=sizeof(D3DVIEWPORT); D3DRECT d3dRect;
vp->GetViewport(&vpd); vpd.dwSize=sizeof(D3DVIEWPORT);
d3dRect.x1 = vpd.dwX; vp->GetViewport(&vpd);
d3dRect.y1 = vpd.dwY; d3dRect.x1 = vpd.dwX;
d3dRect.x2 = vpd.dwX + vpd.dwWidth; d3dRect.y1 = vpd.dwY;
d3dRect.y2 = vpd.dwY + vpd.dwHeight; d3dRect.x2 = vpd.dwX + vpd.dwWidth;
OutTraceD("d3dRect=(%d,%d)-(%d,%d)\n", d3dRect.x1, d3dRect.y1, d3dRect.x2, d3dRect.y2); d3dRect.y2 = vpd.dwY + vpd.dwHeight;
if(dxw.dwFlags4 & ZBUFFERCLEAN )vp->Clear2(1, &d3dRect, D3DCLEAR_ZBUFFER, 0, 1.0, 0); OutTraceD("d3dRect=(%d,%d)-(%d,%d)\n", d3dRect.x1, d3dRect.y1, d3dRect.x2, d3dRect.y2);
if(dxw.dwFlags4 & ZBUFFER0CLEAN)vp->Clear2(1, &d3dRect, D3DCLEAR_ZBUFFER, 0, 0.0, 0); if(dxw.dwFlags4 & ZBUFFERCLEAN )vp->Clear2(1, &d3dRect, D3DCLEAR_ZBUFFER, 0, 1.0, 0);
if(dxw.dwFlags4 & ZBUFFER0CLEAN)vp->Clear2(1, &d3dRect, D3DCLEAR_ZBUFFER, 0, 0.0, 0);
}
} }
res=(*pBeginScene3)(d3dd); res=(*pBeginScene3)(d3dd);
if(res) OutTraceE("BeginScene(3): res=%x(%s)\n", res, ExplainDDError(res)); if(res) OutTraceE("BeginScene(3): res=%x(%s)\n", res, ExplainDDError(res));
@ -685,3 +716,25 @@ HRESULT WINAPI extEndScene3(void *d3dd)
if(res) OutTraceE("EndScene(3): res=%x(%s)\n", res, ExplainDDError(res)); if(res) OutTraceE("EndScene(3): res=%x(%s)\n", res, ExplainDDError(res));
return res; return res;
} }
HRESULT WINAPI extGetCaps3(void *d3dd, LPD3DDEVICEDESC hd, LPD3DDEVICEDESC sd)
{
HRESULT res;
OutTraceD("GetCaps(3): d3dd=%x hd=%x sd=%x\n", d3dd, hd, sd);
res=(*pGetCaps3)(d3dd, hd, sd);
if(res) {
OutTraceE("GetCaps(3): res=%x(%s)\n", res, ExplainDDError(res));
return res;
}
if(dxw.dwFlags4 & NOPOWER2FIX){
if(hd) {
hd->dpcLineCaps.dwTextureCaps|=D3DPTEXTURECAPS_NONPOW2CONDITIONAL|D3DPTEXTURECAPS_POW2;
hd->dpcTriCaps.dwTextureCaps|=D3DPTEXTURECAPS_NONPOW2CONDITIONAL|D3DPTEXTURECAPS_POW2;
}
if(sd) {
sd->dpcLineCaps.dwTextureCaps|=D3DPTEXTURECAPS_NONPOW2CONDITIONAL|D3DPTEXTURECAPS_POW2;
sd->dpcTriCaps.dwTextureCaps|=D3DPTEXTURECAPS_NONPOW2CONDITIONAL|D3DPTEXTURECAPS_POW2;
}
}
return res;
}

View File

@ -46,14 +46,14 @@ struct {
static void HookAdditionalModules() static void HookAdditionalModules()
{ {
for(int i=0; i<ADDITIONAL_MODULE_COUNT; i++){ for(int i=0; i<ADDITIONAL_MODULE_COUNT; i++){
if(!AddedModules[i].Hooked){ if(!AddedModules[i].Hooked){ // if the module is not hooked yet...
HMODULE hModule; HMODULE hModule;
hModule=GetModuleHandle(AddedModules[i].ModuleName); hModule=GetModuleHandle(AddedModules[i].ModuleName);
if(hModule){ // if not hooked yet... if(hModule){ // --- and now it exists ...
HookModule(hModule, 0); // hook it and .. HookModule(hModule, 0); // ... then hook it and ..
AddedModules[i].Hooked=TRUE; // .. mark it as already hooked AddedModules[i].Hooked=TRUE; // .. mark it as already hooked
OutTraceD("CoCreateInstance: hooked module=%s hmodule=%x\n", AddedModules[i].ModuleName, hModule); OutTraceD("CoCreateInstance: hooked module=%s hmodule=%x\n", AddedModules[i].ModuleName, hModule);
CloseHandle(hModule); //CloseHandle(hModule); // do NOT close this handle
} }
} }
} }

View File

@ -90,6 +90,7 @@
#define IDC_POSY 1047 #define IDC_POSY 1047
#define IDC_SIZX 1048 #define IDC_SIZX 1048
#define IDC_SIZY 1049 #define IDC_SIZY 1049
#define IDC_DISABLEFOGGING 1049
#define IDC_HOOKCHILDWIN 1050 #define IDC_HOOKCHILDWIN 1050
#define IDC_MESSAGEPROC 1051 #define IDC_MESSAGEPROC 1051
#define IDC_RECOVERSCREENMODE 1053 #define IDC_RECOVERSCREENMODE 1053
@ -188,7 +189,8 @@
#define IDC_FIXREFCOUNTER 1145 #define IDC_FIXREFCOUNTER 1145
#define IDC_SHOWTIMESTRETCH 1146 #define IDC_SHOWTIMESTRETCH 1146
#define IDC_ZBUFFERALWAYS 1147 #define IDC_ZBUFFERALWAYS 1147
#define IDC_ZBUFFER0CLEAN 1148 #define IDC_ZBUFFER0CLEAN 1148
#define IDC_NOPOWER2FIX 1149
#define ID_MODIFY 32771 #define ID_MODIFY 32771
#define ID_DELETE 32772 #define ID_DELETE 32772
#define ID_ADD 32773 #define ID_ADD 32773

View File

@ -39,6 +39,7 @@ void CTabCompat::DoDataExchange(CDataExchange* pDX)
DDX_Check(pDX, IDC_BUFFEREDIOFIX, cTarget->m_BufferedIOFix); DDX_Check(pDX, IDC_BUFFEREDIOFIX, cTarget->m_BufferedIOFix);
DDX_Check(pDX, IDC_ZBUFFERCLEAN, cTarget->m_ZBufferClean); DDX_Check(pDX, IDC_ZBUFFERCLEAN, cTarget->m_ZBufferClean);
DDX_Check(pDX, IDC_ZBUFFER0CLEAN, cTarget->m_ZBuffer0Clean); DDX_Check(pDX, IDC_ZBUFFER0CLEAN, cTarget->m_ZBuffer0Clean);
DDX_Check(pDX, IDC_NOPOWER2FIX, cTarget->m_NoPower2Fix);
} }
BEGIN_MESSAGE_MAP(CTabCompat, CDialog) BEGIN_MESSAGE_MAP(CTabCompat, CDialog)

View File

@ -50,10 +50,13 @@ void CTabWindow::DoDataExchange(CDataExchange* pDX)
DDX_Check(pDX, IDC_INIT16BPP, cTarget->m_Init16BPP); DDX_Check(pDX, IDC_INIT16BPP, cTarget->m_Init16BPP);
DDX_Check(pDX, IDC_DISABLEGAMMARAMP, cTarget->m_DisableGammaRamp); DDX_Check(pDX, IDC_DISABLEGAMMARAMP, cTarget->m_DisableGammaRamp);
DDX_Check(pDX, IDC_FORCE16BPP, cTarget->m_Force16BPP); DDX_Check(pDX, IDC_FORCE16BPP, cTarget->m_Force16BPP);
DDX_Check(pDX, IDC_WIREFRAME, cTarget->m_WireFrame);
DDX_Check(pDX, IDC_BLACKWHITE, cTarget->m_BlackWhite); DDX_Check(pDX, IDC_BLACKWHITE, cTarget->m_BlackWhite);
DDX_Check(pDX, IDC_USERGB565, cTarget->m_UseRGB565); DDX_Check(pDX, IDC_USERGB565, cTarget->m_UseRGB565);
DDX_Check(pDX, IDC_LOCKSYSCOLORS, cTarget->m_LockSysColors); DDX_Check(pDX, IDC_LOCKSYSCOLORS, cTarget->m_LockSysColors);
// 3D management
DDX_Check(pDX, IDC_WIREFRAME, cTarget->m_WireFrame);
DDX_Check(pDX, IDC_DISABLEFOGGING, cTarget->m_DisableFogging);
} }
BOOL CTabWindow::OnInitDialog() BOOL CTabWindow::OnInitDialog()

View File

@ -56,6 +56,8 @@ CTargetDlg::CTargetDlg(CWnd* pParent /*=NULL*/)
m_ZBufferClean = FALSE; m_ZBufferClean = FALSE;
m_ZBuffer0Clean = FALSE; m_ZBuffer0Clean = FALSE;
m_ZBufferAlways = FALSE; m_ZBufferAlways = FALSE;
m_DisableFogging = FALSE;
m_NoPower2Fix = FALSE;
m_UnNotify = FALSE; m_UnNotify = FALSE;
m_Windowize = TRUE; // default true !! m_Windowize = TRUE; // default true !!
m_HookDLLs = TRUE; // default true !! m_HookDLLs = TRUE; // default true !!

View File

@ -119,6 +119,8 @@ public:
BOOL m_ZBufferClean; BOOL m_ZBufferClean;
BOOL m_ZBuffer0Clean; BOOL m_ZBuffer0Clean;
BOOL m_ZBufferAlways; BOOL m_ZBufferAlways;
BOOL m_NoPower2Fix;
BOOL m_DisableFogging;
BOOL m_SuppressIME; BOOL m_SuppressIME;
BOOL m_SetCompatibility; BOOL m_SetCompatibility;
BOOL m_DisableHAL; BOOL m_DisableHAL;

Binary file not shown.

View File

@ -417,6 +417,7 @@ BEGIN
CONTROL "Set 16BPP RGB565 encoding",IDC_USERGB565,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,159,64,126,9 CONTROL "Set 16BPP RGB565 encoding",IDC_USERGB565,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,159,64,126,9
CONTROL "Lock Sys Colors",IDC_LOCKSYSCOLORS,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,159,76,126,9 CONTROL "Lock Sys Colors",IDC_LOCKSYSCOLORS,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,159,76,126,9
GROUPBOX "3D effects",IDC_STATIC,149,122,144,111 GROUPBOX "3D effects",IDC_STATIC,149,122,144,111
CONTROL "Disable Fogging",IDC_DISABLEFOGGING,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,159,147,96,10
END END
IDD_TAB_EMPTY DIALOGEX 0, 0, 300, 240 IDD_TAB_EMPTY DIALOGEX 0, 0, 300, 240
@ -443,6 +444,7 @@ BEGIN
CONTROL "Fix buffered IO after Win98",IDC_BUFFEREDIOFIX,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,128,109,12 CONTROL "Fix buffered IO after Win98",IDC_BUFFEREDIOFIX,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,128,109,12
CONTROL "Clean ZBUFFER @1.0 fix",IDC_ZBUFFERCLEAN,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,16,116,109,12 CONTROL "Clean ZBUFFER @1.0 fix",IDC_ZBUFFERCLEAN,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,16,116,109,12
CONTROL "Clean ZBUFFER @0.0 fix",IDC_ZBUFFER0CLEAN,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,16,104,109,12 CONTROL "Clean ZBUFFER @0.0 fix",IDC_ZBUFFER0CLEAN,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,16,104,109,12
CONTROL "Textures not power of 2 fix",IDC_NOPOWER2FIX,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,16,92,109,12
END END
IDD_TAB_SYSLIBS DIALOGEX 0, 0, 300, 240 IDD_TAB_SYSLIBS DIALOGEX 0, 0, 300, 240

Binary file not shown.

View File

@ -157,6 +157,8 @@ static void SetTargetFromDlg(TARGETMAP *t, CTargetDlg *dlg)
if(dlg->m_ZBufferClean) t->flags4 |= ZBUFFERCLEAN; if(dlg->m_ZBufferClean) t->flags4 |= ZBUFFERCLEAN;
if(dlg->m_ZBuffer0Clean) t->flags4 |= ZBUFFER0CLEAN; if(dlg->m_ZBuffer0Clean) t->flags4 |= ZBUFFER0CLEAN;
if(dlg->m_ZBufferAlways) t->flags4 |= ZBUFFERALWAYS; if(dlg->m_ZBufferAlways) t->flags4 |= ZBUFFERALWAYS;
if(dlg->m_NoPower2Fix) t->flags4 |= NOPOWER2FIX;
if(dlg->m_DisableFogging) t->flags4 |= DISABLEFOGGING;
if(dlg->m_SuppressIME) t->flags2 |= SUPPRESSIME; if(dlg->m_SuppressIME) t->flags2 |= SUPPRESSIME;
if(dlg->m_SuppressD3DExt) t->flags3 |= SUPPRESSD3DEXT; if(dlg->m_SuppressD3DExt) t->flags3 |= SUPPRESSD3DEXT;
if(dlg->m_SetCompatibility) t->flags2 |= SETCOMPATIBILITY; if(dlg->m_SetCompatibility) t->flags2 |= SETCOMPATIBILITY;
@ -314,6 +316,8 @@ static void SetDlgFromTarget(TARGETMAP *t, CTargetDlg *dlg)
dlg->m_ZBufferClean = t->flags4 & ZBUFFERCLEAN ? 1 : 0; dlg->m_ZBufferClean = t->flags4 & ZBUFFERCLEAN ? 1 : 0;
dlg->m_ZBuffer0Clean = t->flags4 & ZBUFFER0CLEAN ? 1 : 0; dlg->m_ZBuffer0Clean = t->flags4 & ZBUFFER0CLEAN ? 1 : 0;
dlg->m_ZBufferAlways = t->flags4 & ZBUFFERALWAYS ? 1 : 0; dlg->m_ZBufferAlways = t->flags4 & ZBUFFERALWAYS ? 1 : 0;
dlg->m_NoPower2Fix = t->flags4 & NOPOWER2FIX ? 1 : 0;
dlg->m_DisableFogging = t->flags4 & DISABLEFOGGING ? 1 : 0;
dlg->m_SaveLoad = t->flags & SAVELOAD ? 1 : 0; dlg->m_SaveLoad = t->flags & SAVELOAD ? 1 : 0;
dlg->m_SlowDown = t->flags & SLOWDOWN ? 1 : 0; dlg->m_SlowDown = t->flags & SLOWDOWN ? 1 : 0;
dlg->m_BlitFromBackBuffer = t->flags & BLITFROMBACKBUFFER ? 1 : 0; dlg->m_BlitFromBackBuffer = t->flags & BLITFROMBACKBUFFER ? 1 : 0;