Responsive Ad Area
Home » Blog » Java » Desktop


Simple 3D graphics using Java

Isometric or Orthogonal 3D views In this article I show you how to project a surface in 3D using 3 modes for drawing the surface. There is a left hand mode, a center mode and a right hand mode. This same transformation math works for 3D polyhedron objects as well and you could use if for voxel type games. I show some effects you can use on the surface such as zoom, pan, skew etc. This is entirely wire frame. I do not remove hidden lines. I do not fill or texture map. And I do not rotate. I may do all this in future versions of this article. 90 degree rotation is very easy to do. Using basic trigonometry math more fine rotation is not difficult. The Iso3D class I did not have to put this code in its own class. As a matter of fact in such a simple demo application it was more difficult to do...

Widgets/Java Beans/Components

Java Desktop Widgets, JavaBeans and Components GUI applications are made up of Components in a modular manner. These components (parts) are plugged into one another more or less. Some contain others. Below I list some commonly known GUI widgets. Here is a link to a cool set of charts showing Java Swing Components And here A visual guide to Swing Components Frame Menu Bar Button (Press and Toggle) Button Bar Text Label Text Field Text Box Combo Box List Box Icon Dialog Box (popup) Tool Tip Panel Scroll Pane Tabbed Pane Scroll Bar (vertical or horizontal) Progress Bar Check Box (for selections) Option Button (for selections) Resize Bar Tree Viewer Table Viewer I am sure there are more than listed above. And anyone may make custom widgets of any kind for any purpose for more robust or special...

Desktop Applications

Java Desktop Applications Let me explain a few things that will prepare you to run a Java Desktop Application, and other Java Applications as well. If you do not get this right the application won't run. Bytecode example that looks very similar to assembly language. [code language="java"] iconst_2 istore_1 iload_1 sipush 1000 if_icmpge 44 iconst_2 istore_2 iload_2 iload_1 if_icmpge 31 iload_1 iload_2 irem ifne 25 goto 38 iinc 2, 1 goto 11 getstatic #84; // Field java/lang/System.out:Ljava/io/PrintStream; iload_1 invokevirtual #85; // Method java/io/PrintStream.println:(I)V iinc 1, 1 goto 2 return [/code]   Java runs in a virtual machine, meaning this VM (java.exe or javaw.exe) interprets Java bytecode. For the VM to be able to interpret the bytecode it needs to be started up and given...

Skip to toolbar