Blitz 1.88

Blitz3D Forums/Blitz3D Programming/Blitz 1.88

John Blackledge(Posted 2004) [#1]
"***** V1.88 *****
Changed exe code malloc for DEP (Data execution prevention).
Added new 'SystemProperty's:
Direct3D7, Direct3DDevice7, DirectDraw7, DirectInput7, AppHWND and AppHINSTANCE."
- and these mean what? Examples would be nice.


skidracer(Posted 2004) [#2]
They are intended to allow userlib access to the core DirectX7 interface. The original DX7 SDK docs are recomended reading (and experince with compiling c++ userlibs of course) and are available from a number of places on the net although I can't find a link at microsoft.

The most exciting opportunity will be the IDirect3DDevice7::SetRenderState which may allow people to experiment with stencil buffers (I think you have to use a 32 bit graphics mode to get one) and other cool multipass renderworld techniques...


Damien Sturdy(Posted 2004) [#3]
good to see the collisions fixed.. shame my project died a while ago though!


Damien Sturdy(Posted 2004) [#4]
err...this aint lookin good... got a few MAVS already from previously working code, and a mate is having renderworld troubles.. (he will post shortly i suspect.) whats going on? *downloads 1.87*


man that was scary :(


Genexi2(Posted 2004) [#5]
Possible fix for non-pow2 tex's on GF6800 (don't have one, so untested as yet!)


Wonder what the problem was, I got a GF6800 GT here so I could test....


starfox(Posted 2004) [#6]
Also the sound issue is still there


Pepsi(Posted 2004) [#7]
.


Eole(Posted 2004) [#8]
Please give some exemples ....


Filax(Posted 2004) [#9]
still a revolutionary update... (sigh)


Dirk Krause(Posted 2004) [#10]
I guess I don't know what I am talking about :-), but doesn't that mean that one is able to get the handles from the DirectX surfaces? If so, wouldn't that deliver a solution to (as an example) improve the movie support since one is able to adress the objects directly?


Ziltch(Posted 2004) [#11]
The DirectX is going to help with movies/webcam and all sorts of Dll tricks.

Thanks Mark !


Tom(Posted 2004) [#12]
Very simple example (hey, it works! :), changing the render style from gourad to flat shaded:

http://www.tomspeed.com/rendertest.zip

Put the .decls & .dll in userlibs
Const D3DSHADE_FLAT	= 1
Const D3DSHADE_GOURAUD	= 2
Const D3DSHADE_PHONG	= 3

Graphics3D 800,600,32,2

Direct3D7=SystemProperty$("Direct3D7")
Direct3DDevice7=SystemProperty$("Direct3DDevice7")
DirectDraw7=SystemProperty$("DirectDraw7")
DirectInput7=SystemProperty$("DirectInput7")
AppHWND=SystemProperty$("AppHWND")
AppHINSTANCE=SystemProperty$("AppHINSTANCE")

cam=CreateCamera()
PositionEntity cam,0,0,-4

light=CreateLight()
RotateEntity light,60,30,0
sphere=CreateSphere()

While Not KeyHit(1)
Text 0,0,"Press 1,2 or 3 to change the Render Style"
If KeyHit(2) ChangeRenderStyle Direct3DDevice7,D3DSHADE_FLAT
If KeyHit(3) ChangeRenderStyle Direct3DDevice7,D3DSHADE_GOURAUD
If KeyHit(4) ChangeRenderStyle Direct3DDevice7,D3DSHADE_PHONG

RenderWorld
Flip
Wend
End



C++
#define BBDECL extern "C" _declspec(dllexport)
#define BBCALL _stdcall

#include <d3d.h>

BBDECL void BBCALL ChangeRenderStyle(IDirect3DDevice7 *lpDev, unsigned int mode)
{
	int hr = lpDev->SetRenderState(D3DRENDERSTATE_SHADEMODE, mode);
}



Eole(Posted 2004) [#13]
Good, but where we can find the SDK of DirectX 7.0 or can we use the SDK of directX 8.0 ???


Tom(Posted 2004) [#14]
http://nebula.student.utwente.nl/downloads.php

Bottom of page.


sswift(Posted 2004) [#15]
Uh... was a new version of Blitz released? I don't see a news update with it. Where's the TXT file sayting what's changed? I wanna know if I should bother installing it if folks are having problems, and it doesn't add anything I need I'll wait.


sswift(Posted 2004) [#16]
Ahh I see the nondescript news item now... it's at the top. There's always text there and I long ago started just ignoring it as I look at the page. Not really a good idea to keep a news item at the top always like that.

Still need the list of changes though. Or is that stuff in John's post all there is?


Tom(Posted 2004) [#17]
versions.txt in your Blitz3D program folder lists the changes.


BODYPRINT(Posted 2004) [#18]
Your shadow system still seems OK with this update sswift.
Here is the text from versions.txt

***** V1.88 *****

Tightened up collision detection as per bug report postings.

Changed exe code malloc for DEP (Data execution prevention).

Added new 'SystemProperty's:
Direct3D7, Direct3DDevice7, DirectDraw7, DirectInput7, AppHWND and AppHINSTANCE.

Possible fix for non-pow2 tex's on GF6800 (don't have one, so untested as yet!)


sswift(Posted 2004) [#19]
"versions.txt in your Blitz3D program folder lists the changes."

Yes, but I'd have to INSTALL it to get tp that point. I didn't want to install a version which might be buggy.


Tom(Posted 2004) [#20]
Just reinstall 1.87 if you don't like 1.88, it doesn't cause any problems.


jfk EO-11110(Posted 2004) [#21]
Anyway, cool to see the compiler tried to solve that DEP issue. Let's see how things evolve.


fredborg(Posted 2004) [#22]
So who's gonna do stencil shadows?


Eole(Posted 2004) [#23]
thank's Tom


What is the DEP issue ?


bradford6(Posted 2004) [#24]
dilemma:

stencil shadows in DX7 will cause slowdown. why not use DX9?

if PC can't run DX9 then prob won't do very well with DX7 stencil shadow hack.

time for an API "Regime change"


BODYPRINT(Posted 2004) [#25]
DEP is the Data Execution Prevention which was built into Service Pack 2 for XP.

It stops code from running in memory areas that Windows says it shouldn't. It's to help prevent viruses etc from running.

But it has also caused some problems with Blitz apparently, so they have fixed it....apparently. :-)


Tom(Posted 2004) [#26]
Why will it be slow bradford?

And how slow? Will it be slower than a software solution, like sswifts shadow system?

These questions, and more, answered soon in a thread near you! :)

Tom


-=Darkheart=-(Posted 2004) [#27]
"time for an API "Regime change" "

Does that mean bombing Mark's house into the ground and nicking all his stuff?

;)

Yeah it would be VERY cool if B3D could metamorphose to DX9, I doubt it will happen though.

Darkheart


Paolo(Posted 2004) [#28]
Wowowowowow!

I'm getting excited with this dx7 stuff.

Please,
to the directx gurus here,
can you clarify something about what could we access?

By the way, I just installed 1.88, and until now, it seems to run very well, it runs my old code without problems or MAVs.

Thanks!
Paolo


Extron(Posted 2004) [#29]
Possible fix for non-pow2 tex's on GF6800 (don't have one, so untested as yet!)


Confirmed, work fine. :)


Sledge(Posted 2004) [#30]

Yeah it would be VERY cool if B3D could metamorphose to DX9, I doubt it will happen though.



How about BASIC commands to manipulate the existing, shockingly unfriendly DX7 glitz first? And FMOD being fixed.

I thought DX9 libs were already underway, anyhow. :/


sswift(Posted 2004) [#31]
If I'm not mistaken, the DEP thing would affect only the compile process itself, not apps written in Blitz?


N(Posted 2004) [#32]
It would be nifty if we could get the vertex/index buffers from entities (GetIB and GetVB functions, for example- assuming this is how DX7 handles drawing primitives- would allow a lot of configuration). Just having the handle to the device though opens a lot of new options. Including adding new graphical features (you could add your own mesh loader, drawer, support for texture compression, etc. if I'm not mistaken because now you can reference these objects [sortof] as is required by many of the object constructors in Direct3D).

Should be interesting to see what people do with these...


DrakeX(Posted 2004) [#33]
hopefully halo finds a way to access the vertex / index buffers of meshes as well ;) there've got to be some simple pointers in the meshes..

this is a nice little update, just leaves something to be desired. one thing i'm not real clear on - what exactly was fixed with the collision?


Hotcakes(Posted 2004) [#34]
If I'm not mistaken, the DEP thing would affect only the compile process itself, not apps written in Blitz?

I think because of the way the compiler linked the runtime.dll into each Blitz executable, come runtime DEP was picking up on some 'illegal' way of it being accessed.


Neochrome(Posted 2004) [#35]
Can some BrightSpark work on making DOT3 work realy fast and perpixal shaders work in dx7 using this new patch?


@rtur(Posted 2004) [#36]
DOT3 works fine
no, u can't use pixel shaders in DX7:(


The Caffeine Kid(Posted 2004) [#37]
Is the FMOD problems with MODS/XM/IT fixed?

If not then I have to stay with 1.86 :(


Strider Centaur(Posted 2004) [#38]
Well I guess we windows 2000 users are lucky, never ran into a DEP problem. :)

Btw, this foliage thing is the cats meow, and I will be giving you tons of credit on the splash screen. :)

So that you, psionic and that other guy who coded the data base interface. LOL

Don't wory, Ill have the name before I release anything. :)


Tom(Posted 2004) [#39]
Caffeine Kid, why not render the MOD/XM/IT to Ogg?


Ruz(Posted 2004) [#40]
I demand the finest stencil shadows available to humanity


Damien Sturdy(Posted 2004) [#41]
okay, so what exactly is a "stencil shadow"?


Ruz(Posted 2004) [#42]
dunno, but it sounds nice eh?


Damien Sturdy(Posted 2004) [#43]
yup! lol


Ruz(Posted 2004) [#44]
Though i don't know how it works technically ,visually its just a shadow that is sharply defined, and accurate to the object that is castng it.
Don't know how essential they are though since the player shadows in GTA san andreas are just 'faked' by the looks of them.


Hotcakes(Posted 2004) [#45]
Is the FMOD problems with MODS/XM/IT fixed?

Being that there's no mention of another FMOD update (although FMOD itself has been updated since), I don't think you're in luck. Actually I think someone has specifically stated in the bug reports forum somewhere that the FMOD problems remain.

Caffeine Kid, why not render the MOD/XM/IT to Ogg?

I'd assume he doesn't want his soundtrack to be 10 times the size.