This article briefly introduces the special effects based on the j2's graphics technology. j2's is a Java version reduction for mobile phones, PDAs, and other mobile and embedded devices. Thanks to the popularity of Java mobile phones, the application prospects of j2's are very impressive.
Special effects based on j2's graphics technology
The dynamic special effect display of graphic images has practical needs in application development. However, due to the limitations of devices, therefore, on the basis of understanding the technical architecture and Related Technologies of the graphic image processing, the special effect display of the graphic can make the interface of the application more beautiful, it also provides an algorithm reference for the development of animations and games in j2s.
There are many development technologies for mobile apps, and Java is favored by its "writeonce, runanywhere" features. When Java evolved to Java2, SUN developed Java into four versions to meet the market demand for flexibility and personality: java2javasiseedition for developing enterprise service applications) j2SE (Java2standardEdition) for general PC applications, Java2MicroEdition for embedded devices and consumer electronic products, and SmartCard for smart card development.
I. Technical Architecture of j2s
It is a Java version reduction for mobile phones, PDAs, and other mobile and embedded devices. Thanks to the popularity of Java mobile phones, the application prospect of j2-based graphics is very promising. With a modular structure, the bottom layer is the operating system of the host machine, which is divided into three layers:
1. Java Virtual Machine (JVM)
The Java Virtual Machine is implemented according to certain configurations. The CDC configuration corresponds to CVM, And the CLDC configuration corresponds to KVM.
2. Configuration layer)
The configuration layer defines the minimum functional set of the Java Virtual Machine and the minimum set of the Java class library, which is the basis of the profile layer. Currently, all embedded devices are divided into two types: one is embedded devices with limited computing functions and limited power supply (such as PDAs and mobile phones), which is defined as DLDC; another is an embedded device (such as a network appliance) with relatively good computing power and ample power supply. It is defined as CDC.
3. Application Model layer Profile)
Profile is the specification of the Architecture above Configuration. It defines different types of Java class libraries and APIs (application interfaces) for different device types (such as mobile phones and set-top boxes ), added additional JVM feature sets and class libraries. Currently, only one profile (mobileinformationdeviceprofile) is defined in CLDC ).
The MIDP and CLDC specifications are defined in MIDPSPEC and CLDCSPEC respectively. These specifications define the basic part of the MIDP application, which is called the MIDlet.
2. j2-based Graphic Programming
The basic Abstract Image of the MIDP User Interface UI is the screen. The Screen class encapsulates device-oriented graphics and user interaction. Each application can display only one screen, and only entries on the screen can be viewed or used.
The Java class design of the MIDP User Interface API is not based on javajavasactwindowtoolkit (AWT) Class
It is specially designed for small mobile information devices such as mobile phones and pagers. These devices only have limited screen sizes and keyboard performance. When programmers use MIDP to write graphics applications, they can only use MIDP or CLDC APIs.
MIDP APIs have "advanced" high-level) and "low" low-level) UI classes. Advanced User Interface classes (such as Form, List, TextBox, TextField, Alert, and Ticker) have the device adaptation function, which supports images, text, text fields, and single-choice buttons. Low-level user interface classes (such as the Canvas, Graphics, and Image classes) Allow the operator to draw freely.