View Full Version : 3d rendering

22-04-2006, 11:04 AM
Hello there.

I've recently started coding a bit midlet pascal and found it was nice to use.
I've tried to implement a little software renderer in this language and until now it runs quite fast(though not for big polygons).
I'm using the half-space algorithm as written in the article over at devmaster.net but i don't use 8x8 pixel tests yet. i'll try to get some images up later and i can post the source if anybody are interested

it just got me wondering. Do java 2 me have some sort of inbuilt 3d support?

24-04-2006, 12:33 AM
Yes, it has. I don't know if Midlet Pascal can use it, probably not because there were a lot of things missing when I checked it. To use th 3D features you need MIDP 2.0. The Wireless Toolkit brings the whole reference of MIDP 2.0, and several examples that can be run in the bult-in emulator. It's really cool. :D I liked Midlet Pascal very much, but a lot of support is missing. Also Midlet Pascal doesn't generate microjava byte-code, instead the programs are interpreted by an engine in j2me, so it's not optimal.

24-04-2006, 05:09 AM
Also you can write your own wrappers for other Java classes and import them into MidletPascal - so if there is a nice 3D library on the phones you want to use then all thats needed is a wrapper library (done in Java) that gets imported like a normal Pascal unit - check out the Sensor Support and the Game Lib stuff (All MIDP2.0 as far as I know).

24-04-2006, 06:13 AM
"generates low-level, small and fast Java‚Ѣ bytecode"?

24-04-2006, 08:29 AM
Also Midlet Pascal doesn't generate microjava byte-code, instead the programs are interpreted by an engine in j2me, so it's not optimal.

Can you clarify where you got this information/impression from?

24-04-2006, 08:43 AM
More information about the 3D api can be found @
the API is found in the javax.microedition.m3g package.

There is also an article here -
entitled "Advanced Game Development with the Mobile 3D Graphics API" which some of you might find interesting.

So as cairnswm says, all that's needed is a Lib_* wrapper around it and it should be usable in MP. Anyone got the patience to create one and try it?

24-04-2006, 09:02 AM
i'll surely take a look at it. I'll write if i manage to get something working with midlet pascal

24-04-2006, 09:11 AM
Or speak to Pilgrim on the MidletPascal forums - his hobby seems to be making LIBs for Midlet Pascal :)

24-04-2006, 01:27 PM
I supposed that from this:

found that the CPS is only 1/3 of its original j2me version

You can improve MP execution speed only if you can write libraries in Java


And I could be wrong too, but seems logical. :?