V0.5

BlitzMax Forums/MiniB3D Module/V0.5

simonh(Posted 2008) [#1]
Download from here.

Collisions and picking are B3D-speed now and there's one or two other handy additions like CameraProjMode (thanks Klepto!) and ClearWorld, as well as the usual smattering of bug fixes.

C++ code is not optional anymore - you must have MinGW installed.

As always let me know of all the various quirks and issues you encounter, and I'll do my best to release V0.51 as quickly as possible...


Warner(Posted 2008) [#2]
Seems to be working nicely. Thanks simon!
*edit* collisions work great!! :D


Digital Anime(Posted 2008) [#3]
Downloading now, thanks a lot :-)


Extron(Posted 2008) [#4]
Just three word : Very good work.
Multi-surface anim meshes works very well now.

Thanks Simonh.


Kev(Posted 2008) [#5]
thanks for the update simon.


slenkar(Posted 2008) [#6]
thanks simon

i looked in functions.bmx and clearworld still seems to be blank, anyone else get this?


johnnyfreak(Posted 2008) [#7]
great! it wroks fine! tnx ;)


GfK(Posted 2008) [#8]
I haven't used MiniB3D until about an hour ago.

Its actually rather good.


Ross C(Posted 2008) [#9]
Continue your work gfk! GO!


GfK(Posted 2008) [#10]
This should be the official Max3D, imho.


deps(Posted 2008) [#11]
Holy crap, just in time when a nice idea popped into my head!
Will give 0.5 a go, thanks a lot!


siread(Posted 2008) [#12]
Simon, the Max2D stuff has stopped working for me. If I run the example in 0.451 it's fine, but 0.5 i just see the teapot.

Doh! Forgot the Const in minib3d.bmx.

However, I don't seem to be getting a window mode anymore...

Also suffering a massive frame rate hit. Gone from solid 60 to 30ish. Am I forgetting something else?


z4g0(Posted 2008) [#13]
Simon, the Max2D stuff has stopped working for me. If I run the example in 0.451 it's fine, but 0.5 i just see the teapot.

same here...
I tried also replacing tBlitz2D.beginMax2D & tBlitz2D.endMax2D with old version ones, but nothing: renders only the 3D canvases (with a strange cls artifacts) and back screen in Max2D areas ( out from 3D viewports)


siread(Posted 2008) [#14]
Did you open minib3d.bmx and set the MAX2D=true?


z4g0(Posted 2008) [#15]
oh damn no sry :=)

now works good!

on the fly: seems to get a bit lower framerate, but I could be wrong... tomorrow I'll test better.

ah, other thing: I still have z order problem on alpha brushes, like the 0.45 (but not 0.42, for example)


*(Posted 2008) [#16]
Excellent stuff, im with gfk on this it should be Max3d :)

Basically its the same as most of the other Max stuff, source that can be compiled with the IDE :)


simonh(Posted 2008) [#17]
Thanks for the positive comments!

i looked in functions.bmx and clearworld still seems to be blank, anyone else get this?

I forgot to add it to the functions list - you can use it by calling TGlobal.ClearWorld()

However, I don't seem to be getting a window mode anymore...

The Graphics3D parameters have changed sightly to exactly match Blitz3D.

Also suffering a massive frame rate hit. Gone from solid 60 to 30ish. Am I forgetting something else?

Can't think of anything I've changed that should affect the speed - can you pinpoint where the slowdown is occuring?

ah, other thing: I still have z order problem on alpha brushes, like the 0.45 (but not 0.42, for example)

I'm pretty sure it's a driver/card issue, but I'll take another look - it might be possible to restore the old behaviour.


LT(Posted 2008) [#18]
Any chance that shaders from Klepto's extended version can be added to this, since it is no longer getting updates?


plash(Posted 2008) [#19]
I think the standard minib3d was intended to be as blitz3d-ish as possible (correct me if I'm wrong, blit3d doesn't do shaders), and as low spec as possible?


LT(Posted 2008) [#20]
I'm aware of that, but Klepto's shaders don't interfere with the rest of the functionality and I know a lot of people would like that to be available in the version that is currently being updated. I know I would!


siread(Posted 2008) [#21]
Ok, window mode is fine now. However the game still plays like it's running in Debug mode.

It appears to be a problem with LinePick. Basically if my camera can't pick the football because it has been obscured by the stadium I would hide the stadium. Now the stadium alpha is flickering all over the place when there is no need. I removed all linepick commands and it's running smoothly again. Here's my pick code:

Global stadalpha:Float = 1
	Local ball:TBall = TBall.SelectActiveBall()
	Local ent:TEntity = LinePick(EntityX(camera_match),..
 EntityY(camera_match), EntityZ(camera_match),..
EntityX(ball.mesh)-EntityX(camera_match),..
EntityY(ball.mesh)-EntityY(camera_match),..
EntityZ(ball.mesh)-EntityZ(camera_match), 1000)
	If ent = stadium 
stadalpha:-(0.25 * GetGameSpeed()) 
Else 
stadalpha:+(0.25 * GetGameSpeed())
EndIf
		
	ValidateMinMaxFloat(stadalpha, 0.0, 1.0)
	EntityAlpha(stadium, stadalpha)



siread(Posted 2008) [#22]
Actually, I've just noticed that collisions aren't working at all. Have the collision/picking commands changed?

I'm using ellipsoid-to-polygon collisions.


plash(Posted 2008) [#23]
Weirdness in linux (7.04 - not my tablet), the firepaint demo worked fine, the second one I tried was cubemapping.


And caused this afterwards (things keep disappearing on me!)


This machine has an ATI Radeon 7500 Mobile, using dual boot in windows the cubemapping and countless other things in the extended (and standard) version work.


slenkar(Posted 2008) [#24]
oh yeah i found clearworld in tglobal thanks


simonh(Posted 2008) [#25]
Actually, I've just noticed that collisions aren't working at all. Have the collision/picking commands changed?

I'm not sure what you mean. The collisions and picking commands do work as you can see if you run the camerapick and sliding collisions examples.

Can you be more specific?


siread(Posted 2008) [#26]
Ok, I've narrowed it down a bit. Basically when I want to reset my ball position I use ClearCollisions() then set up my collisions again.

Try adding this code to the SlidingCollision.bmx and instead of doing Collisions 1,2,2 call SetUpCollisions()

Function SetUpCollisions()
	ClearCollisions()
	UpdateWorld()
	Collisions 1,2,2
End Function


It works fine in 0.45 but not 0.5. It's like ClearCollisions() turns off collisions permanently.


siread(Posted 2008) [#27]
Also, in EntityVisible.bmx if you set EntityPickMode for the two spheres they can no longer see each other.


simonh(Posted 2008) [#28]
Thanks Si. I'll look into it.


Zethrax(Posted 2008) [#29]
Ok, I've narrowed it down a bit. Basically when I want to reset my ball position I use ClearCollisions() then set up my collisions again.


I haven't played around with MiniB3d yet, but in Blitz3D you would use ResetEntity to achieve that result.


siread(Posted 2008) [#30]
Another little command I never knew about! Thanks, Bill. :)


siread(Posted 2008) [#31]
Any news, Si?


simonh(Posted 2008) [#32]
Haven't had a chance to do anything on it yet, will probably be a few more days before a new version.


ziggy(Posted 2008) [#33]
Const USE_MAX2D = True ' true to enable max2d/minib3d integration. may cause 3d not to be rendered on some setups, if so set to false

Does anybody know wich setups have problems with this?


siread(Posted 2008) [#34]
Not sure exactly, but I only had a handful of complaints out of several hundred users with my last beta.


ziggy(Posted 2008) [#35]
I had problems with it before I updated my intel drivers. Just to know if it is a intel driver issue. anyone has more info on this? Simonh?


GfK(Posted 2008) [#36]
I wonder if that's related to the problems Blitzmax had until very recently on Intel GMA/ATI graphics cards?

The latest Intel drivers work perfectly but I don't have an ATI card any more so I can't check the latest Catalyst drivers. Maybe if you've had problems before you could A) Find out what hardware is being used when problems occur, and B) Recommend a driver update and see if that fixes it.


ziggy(Posted 2008) [#37]
It works wonderfully with intel GMA with latest drivers. I'm just wondering if that was the problem. In that case I would leave the max2d flag to true. But that's just gessing.
Does anybody have more information on which graphics cards did have problems with max2d within minib3d?


ChaosCoder(Posted 2008) [#38]
miniB3D work perfect with ATI X1600Pro. But i still have Z-Sort problems with my MacBook :(


simonh(Posted 2008) [#39]
V0.51 is up - a minor bug-fix update.


Sanctus(Posted 2008) [#40]
Can you do orthographic views with CameraProjMode?? :D
This must be so nice.


Sanctus(Posted 2008) [#41]

An example of how to make a isometric view


HrdNutz(Posted 2008) [#42]
sorry fixt :>


simonh(Posted 2008) [#43]
What are your system specs?


LT(Posted 2008) [#44]
I can't get the examples to work. I'd been playing around with Klepto's extended for awhile, but since he's not making updates, I thought I'd get V0.51 and try it out.

The examples just open up black windows for me. Any ideas?


simonh(Posted 2008) [#45]
What graphics card have you got?


LT(Posted 2008) [#46]
Radeon 9800 Pro, but I don't think that's the problem since it also does not work on my laptop. I compiled using the command line BMK.

I had to remove these lines from TGlobal.bmx in order to compile, otherwise, I was getting an error...

?debug
d=0
?
?Not debug
If d=0 Then d=16
?

Also, I changed the first line of the example from Import "../minib3d.bmx" to Import sidesign.minib3d in order to avoid the compile error "Module does not match commandline module."


LT(Posted 2008) [#47]
Btw, I can't get this to run in 1920x1200 properly on my Radeon - works fine on my laptop, which has an older (but GeForce) card. Does anyone know why this is an issue?