Language :
French / Francais
About :
The idea is to provide a FREE Open Source Real Time 3d engine for phones and mobile devices.
Currently don't expect to play quake on your device, but it can display spinning logos with lightning (like old-school demo of early 1990s).
Upcoming, Features are : texture mapping, Rubik's cube game

Main Features :
Portable to MANY devices (vs native 3D)
Rendering Modes : Vertex, Wire-frame, Filled, Color, Back-face Culling, Dynamic Lightning (Fresnel), Triangle Filler, Z-Sort

Requirements :
It is available for different profiles more or less based on MIDP API (Mobile Internet Device Profile) : Supported device are too long to mention (today Diet3D has been tested over 30 devices, see testers)

Contact :
Project URL is :
I started this stuff as a showcase of my skills in the Java Programming Language.
I also have a résumé online , and I am to hire :
You can reach me Philippe COVAL at for Questions, Remarks, Ideas, Features Request, and bug reports
Project Official name is Diet3D (because Mini3D was already one of my project)

Support Author & Software:
Because I am not paid (so far) for this project, it does not mean that I don't need encouragements :
Please Can you visit sponsors at top/bottom of the page (I'll get a few cents)
Also contact me if you want a specific 3D logo for yourself or your company. I can charge a few bucks for that (or making some documentation).

Free & Licence :
It is GPL Licenced That's mean you can afford it for $0 and for $0 extra you'll get the source codes.
BUT you have no right until you read this :

Contribute :
PLEASE reports me your tests, patches, documentations are also welcome, (I can set a CVS up if needed)

Download Byte Code & Sources (GPL Licenced)
There is a GPL version of the sources (midp1.0 wireframe only) at :

Current version of the sources are not public (contact me if interested).

Please visit sponsors or donate, for speeding up project.
Linux J2ME + Tutorial
Funny Applets


On a Real phone device (Over the Air, with WAP, GRPS or BlueTooth)
If you open this page with your mobile (it detects, wap or html) and select .JAD link (or .jar if problems)
If having trouble with this address, you can try this alternate ones (SE dont support redirection)
It should install by itself (fast , because it is less than 10Kb)
On a Real phone device (Beam it with cable,Infra Red,Bluetooth etc)
Pick the both files .jar & .jad
It is Available in several flavor
WWW / (java Applet)
Inside your web browser (java must be supported) :
Inside Micro Emulator Applet (not working w/ MS JVM)
On your Desktop Comp
# with RI 
/opt/midp2.0fcs/bin/midp -transient -force ${URL}

# with java
appletviewer applet.htm
java Diet3DApplet 


Work in progress & TODO's
Look at OpenGL ES
Think about math optimizations
Try ant vs gmake
Port to more plate-form using API extensions, Deploy for ExEn , KPN, Brew, Mophun, MS SmartPhone, etc
Working on C++ port for SymbianOS (help welcome)
Texture mapping
ReDesign and freeze some API (partially inspired from M3G JSR-184)

2010-03-02 :
Diet3D ported to blackberry
Tested on blackberry Curve 9900
2008-10-24 :
Work in progress , android port is possible, currently tracing lines...
Random notes :
2004-04-23 :
Since I got a new full time job, I let this project on sleep state.
I will release source code if enough people ask for it in the "rzr-en Forum"
and a texture mapping code still needs to be debugged (see forum)
Thank everyone for testing,
2004-04-01 :
Remaining Random bugs on 3210i 3650
Misc Info move here from now on :
2004-03-04 : Version 0.9
Nokia3650 @ mahadeva1 : tux/spin/zsort+light = 6-9 Fps cube+zsort+light= 32fps cube+pixel=7fps
cube/spin/pixel = 5-8 pfs @ Nokia7650
dyn light
exen / supported on panasonic
works again (one profile more)
2004-02-25 :
support for PalmOS (.prn)
ZSorting (wip)
Pixel Filler (wip)
Ported to Doja (Nttdocomo / Imode) (wip)
2004-02-01 :
Project renamed to Diet3D (mini3d is another of my projects), btw I thought about other names like Mobile3d ? PoorMan3d? Handy3d?
GUI added (Info Button)
Filled Face Mode for midp1.0
Profile Detection / Redirection
Inverse video (black on white)
2003-12-03 : Port to ExEn v2 API (
ExEn SDK seems quite usable under Linux
PVC gen works, the emulator as well (see doc)
2003-11-24 : Tested and Code frozen
Bugs fixed
See troubleshooting section if curious
Display Fps stats, interact with keys
2003-11-18 : Optimizing
Some optimizations, join classes together, macros
New Sphere shape
2003-11-17 : Demo Released for 3 profiles
Key toggle rendering modes and shape
Using Nokia extensions with Nokia SDK
2003-11-16 : Fast lightning rendering
Using Timer Thread at 10fps
Started to Optimize Maths (unroll loops, reuses objects etc)
MicroEmu applet
2003-11-14 : Use Preprocessor
I Use a preprocessor from now on to generate midp 1.0 / 2.0 sources
Project tree changed (also usable with ktoolbar)
Disabled some rendering features (will add them once optimized)
2003-11-13 : 1st Release @ 2fps+
Back-ported to 1.0 and works
Back face culling
Disabled all 2.0 extensions (will add them again later)
Works also with mipd2.0fcs (Reference implementation)
2003-11-11 : Testing Alpha Engine
new applet : port of j2me 3d engine as an applet (or application) , new sources
2003-11-09 : Getting Familiar with tools
Page shows up
I thought about adapting a 3d applet made some years ago but for some reasons I preferred to start it over from scratch.and remain it free (as libre).


I like to thank all the users and devices owners who took time to test my buggy midlets.
Reports if it works on your device
Wiki :
Or email me :
Supported Devices : (brand, model , (comments) @ tester#date )


  1. HTC SPV C500 (Orange) on Windows Mobile (fastest ever saw so far)
  2. Nokia 6630
  3. "Nokia6600/1.0 (3.49.1) SymbianOS/7.0s Series60/2.0 Profile/MIDP-2.0 Configuration/CLDC-1.0" (midp2.0 ,176x208x16b , 150 Mhz ) @ Hoppa#20031124 , fisch , Hiisty (v3.42.1) , robban, sKiz0,6566,015_291,00.html
  4. Motorola V525, "MOT-V525M/0B.09.1DR MIB/2.2 Profile/MIDP-2.0 Configuration/CLDC-1.0 UP.Link/"
  5. Motorola i730 @ kjkjkjkiu (0fps on pixel and zsort)
  6. Motorola V600 "MOT-V600/0B.09.1DR MIB/2.2 Profile/MIDP-2.0 Configuration/CLDC-1.0"
  7. Sony-Ericsson P900 (midp2.0 200Mhz) @ zell|rhk
  8. Sony-Ericsson V800 : "Vodafone/SonyEricssonV800/R1S025 Browser/SEMC-Browser/4.1 Profile/MIDP-2.0 Configuration/CLDC-1.1" @
  9. Sony Ericsson Z1010 @ jojo (tux zortlight) = 11 FPS @ jojo
  10. Sony Ericsson K700i "SonyEricssonK700i/R2A SEMC-Browser/4.0 Profile/MIDP-1.0 MIDP-2.0 Configuration/CLDC-1.1" = ~17-20fps tux zsort+light
  11. Sagen myV-65 (midp2.0) : "SAGEM-myV-65/2.0 Profile/MIDP-2.0 Configuration/CLDC-1.0 UP.Browser/ (GUI) MMP/1.0" Ecco@fr#20031227
  12. Sanyo8100
    (1fps) @
  13. Samsung sgh D500 @ pseudogaetan (support redirect)
  14. Samsung ??? @


  15. "NokiaN-Gage/1.0 SymbianOS/6.1 Series60/1.2 Profile/MIDP-1.0 Configuration/CLDC-1.0" @ glass#20040112,
  16. Nokia 7650 (Serie 60 , color 176x208) "Nokia7650/1.0 SymbianOS/6.1 Series60/0.9 Profile/MIDP-1.0 Configuration/CLDC-1.0 UP.Link/" @ mrhill#20040125/c, fov#20040116 , patrikcrs , Hiisty#20031116
  17. Nokia 7250i @ szilsan "Nokia7210/1.0 (4.18) Profile/MIDP-1.0 Configuration/CLDC-1.0 UP.Link/5.1.1a"
  18. Nokia 7210 @ anton@ru#20031124
  19. "Nokia6650/1.0 (13.89) Profile/MIDP-1.0 Configuration/CLDC-1.0"
  20. Nokia 6310i
  21. Nokia6100/1.0 (05.16) Profile/MIDP-1.0 Configuration/CLDC-1.0 (4k colors) @ , MXV , alfy1@fr , xmd@fr#20031203 (5.52)
  22. Nokia 5210i (col 96x64) @
  23. "Nokia5100/1.0 (4.05) Profile/MIDP-1.0 Configuration/CLDC-1.0" "java/lang/NullPointer/Exception" (menu) @
  24. Nokia 3650 (150 Mhz , gprs, 176x208, col 4096) "Nokia3650/1.0 SymbianOS/6.1 Series60/1.2 Profile/MIDP-1.0 Configuration/CLDC-1.0 UP.Link/" "Nokia3650/1.0 (4.13) SymbianOS/6.1 Series60/1.2 Profile/MIDP-1.0 Configuration/CLDC-1.0 UP.Link/1.1@" mahadeva1
    toco#20040122 , potsmoker , JyriH_
  25. Nokia3595/1.0 (7.00) Profile/MIDP-1.0 Configuration/CLDC-1.0 UP.Link/1.1 @
  26. Nokia 3510i "Nokia3510i/1.0 (03.51) Profile/MIDP-1.0 Configuration/CLDC-1.0 UP.Link/5.1.1a (Google WAP Proxy/1.0)" @ anAKiN(cable)#20031230
  27. Nokia 3410 (b/w , 1st generation of j2me) @
  28. Nokia3300/1.0 (4.05) Profile/MIDP-1.0 Configuration/CLDC-1.0 UP.Link/5.1.1a @ keysie12#20040122
  29. Nokia 3210i
  30. Nokia 3200 (64 KB) "Nokia3200/1.0 () Profile/MIDP-1.0 Configuration/CLDC-1.0 UP.Link/5.1.1a" @ neonatus #20040113=52pfs


  31. Siemens S55 @ bamboos#20031124
  32. Siemens MC60 (midp1.0) @ Lenny^^#20040126 (xfer only the jar file)
  33. Siemens SL45i @viraptor#20040129
  34. Siemens C55 @
  35. Siemens M55

  36. Sony-Ericsson T630 (128x160) @
  37. Sony Ericsson T610 (midp1.0) "SonyEricssonT610/R101 Profile/MIDP-1.0 Configuration/CLDC-1.0 UP.Link/" @ valdo404
    , Bertil@se#20031220, eirikhm@no#20031217, maczar
  38. Sony-Ericsson z600 (midp1.0) @ beady#20040113=CubeWire30fps
  39. Sony-Ericsson P800 (midp1.0) : @ nuk#20040207 , Moak#20040116=cube_wf25fps , caos

  40. Motorola : T720 "MOT-T720/G_05.07.23R MIB/2.0 Profile/MIDP-1.0 Configuration/CLDC-1.0 UP.Link/" @ whickie
  41. motorolla a835 @ trippah

  42. Sagem SX1 (Symbian6) mem=114688
  43. Samsung E700 (SGH-E700 Firmware E70XADA1) @ xmd@fr#20031203 "SAMSUNG-SGH-E700/BSI UP.Browser/ (GUI) MMP/1.0"


  44. Palm / I TungstenT2 + Sun JVM (midp1.0)
  45. Palm m515 (Palm OS 4.1 + java HQ 1.0) (midp1.0) @
  46. panasonic gd87 (exen file must be converted) @ vinou
  47. Samsung SGH-E700 "SAMSUNG-SGH-E700/BSI UP.Browser/ (GUI) MMP/1.0 UP.Link/5.1.1a"

Unsupported devices (please help?) :
Other Hardware To test :


Here are some java stuff and other projects I was involved in.
J2ME 3d Engine (2003)
Read details on this page
open Applet window (port of engine to Applet's AWT)
3D Engine (100% java 1.0) + Vrml + live motion capture and streaming (2000)
open applets window
visit website
Psychelic Applet (1997)
funny 2D effect
open applet window
Database Wizard (1998)
auto-generated gui for databases
short doc
Raising island (1996)
I think thats my first applet
open applet window
I've been involved in other projects, you can check them out :
3d for the web (java+vrml+rmi+eai)
free pinball game (C++/OpenGL/SDL)
The Win32 port (House Version)
Free 1st person shooter game (C++/OpenGL/SDL)
My Linux and open source Contribs
Free Simple 3D toolbox for conversions etc (C)
used in previous projects
Diablo like game project (in Java)


Environment & Tutorial
Linux J2ME + Tutorial
The problems & the tracks
no java.awt.* : nevermind we dont use them just Graphics
java.awt.Graphics ~!= javax.microedition.lcdui.Graphics : just replace or/and adapt
No double or float, sqrt, cos, and trigo : fixed point reals, tables, limited developments etc
Solutions & Explanations :
I created a MathFixed class that does float operations and trigonometric on int's and sinus are stored in a table.
For info the 3D mesh was generated in java with a external mini3d toolbox,
Compute sequential rotations
This could be also run in an applet or application (just replace imports)
Using a Preprocessor in Java ? (H4x0r stuff)
Most of the code is the same between different sdk and api, To ensure genericity I use GNU cpp preprocessor to generate java file, Java Reflexion could solve this ugly method but can't be used in j2me.

If you familiar with C or C++ (or Povray) using a preprocessor, should not be a trouble for you. Else here are some basic sample code :

// file://~/
#ifdef MIDP20
#define paintTriangle(g,a,b,c,col)  { \
     DirectGraphics dg = DirectUtils.getDirectGraphics(g); \
     dg.fillTriangle(a[0],a[1],b[0],b[1],c[0],c[1], 0xFF000000|col ); \
#else //default
#define paintTriangle(g,a,b,c,col)  { \
        g.drawLine( a[0] , a[1] , b[0] , b[1] ); \
        g.drawLine( a[0] , a[1] , c[0] , c[1] ); \
        g.drawLine( c[0] , c[1] , b[0] , b[1] ); 

class MyCanvas { // ...
  protected void paint(Graphics myg) { paintTriangle(myg,mya,myb,myc,mycol); }
Then you need to "compile the file"
cpp -undef -fno-show-column -DMIDP20 -C -P -I. -I \
 < >
And you'll get a new file where macro was replaced :
// file://~/
class MyCanvas { // ...
  protected void paint(Graphics myg) { 
     DirectGraphics dg = DirectUtils.getDirectGraphics(myg); 
     dg.fillTriangle(mya[0],mya[1],myb[0],myb[1],myc[0],myc[1], \
           0xFF000000|mycol );
Got the Idea ? It is pretty simple , but can really be obfuscated thats why Java designers removed this feature in the language.
Evolutions & Révolutions :
Store mesh in compressed stream not class, and make a parser because there is a 32Kb file class limit :
java.lang.OutOfMemoryError: Mesh: Maximum byte code length (32kB) exceeded
Compute combinated rotations with Quaternion
Check for Stability in Numerics
Re-implement 3D algos for hidden faces removal (Zsorting, Zbuffer, BSP etc)
Texture mapping and lightning etc


Register this site they provide free logos games, SMS and ringtones once subscribed

some unlocking phone informations
Last modified: Sat Apr 21 01:38:02 CEST 2007