OpenGL - application programming interface
computer science crazy|
Joined: Dec 2008
22-09-2008, 09:18 AM
OpenGL is a widely-accepted application programming interface (API) for interactive 3D graphics rendering and 2D imaging. It provides device-independent support for common low-level 3D graphics drawing operations such as polygon specification, basic lighting control, transformation specification, and framebuffer operations like blending and depth-buffering.
It also provides mechanisms for sending and retrieving 2D images to and from the framebuffer, and integrates 3D graphics with 2D imaging through texture mapping. While other low-level graphics APIs have provided similar functionality to that of OpenGL, OpenGL takes a novel approach in the presentation of many of its features.
In addition to providing a simple model for combining 3D graphics with 2D imaging, OpenGL makes a clear separation between high- and low-level functionality, stresses fine-grained control and feature orthogonality, and is designed for excellent performance from basic PCs to high-end graphics workstations.
OpenGL also specifies a fixed rendering pipeline that both provides a model for implementations and a clear foundation for adding new functionality. ..
Use Search at http://topicideas.net/search.php wisely To Get Information About Project Topic and Seminar ideas with report/source code along pdf and ppt presenaion
Joined: Apr 2012
20-08-2012, 01:05 PM
1OpenGL.doc (Size: 208 KB / Downloads: 37)
Because playing games on personal computers has become so popular, and so many dazzling animations are appearing in movies, peoples are particularly interested in developing 3D graphics applications. OpenGL is a very useful tool to design a 3D scene.
OpenGL emerged from Silicon Graphics, Inc., in 1992 and has become a widely adopted graphics application programming interface (API). It provides the actual drawing tools through a collection of functions that are called within an application. It is available (usually through free downloads over the Internet) for all types of computer systems. OpenGL is easy to install and learn. One aspect of OpenGL that makes it so well suited for use in a computer graphics is its “device independence”, or portability. An OpenGL program can be developed and run on different computers.
OpenGL offers a rich and highly usable API for 2D, 3D graphics and image manipulation. Using it, people can progress rapidly and produce stunning animation in a short period.
Transformations are of central importance in computer graphics. We use affine transformations in 3D case, including translate, scale, rotations in 3D. We have designed tools used to shift, scale, and rotate figures through the “current transformation,” and OpenGL’s matrix operations are used to facilitate this feature. An overview of the OpenGL viewing pipeline is developed, and the roles of the model view, project and implimentationion, and view port transformations are described briefly. The drawing of 3D objects using OpenGL’s tools is developed.
A FLAT HOUSE
In this part, we first try to use the basic 3D drawing functions of OpenGL to draw a simple “house”. This house only has three walls and one object inside. We use parallel project and implimentationions to visualize an example 3D scene comprised of simple wire-frame objects.
This “flat house” drawing based on the simple “parallel project and implimentationion”, shown in figure 1. The view volume is a rectangular parallelepiped (i.e. a box), whose four sidewalls are determined by the border of the window and whose other two walls are determined by a near plane and a far plane. So the 3D point (x, y, z) project and implimentations to (x, y, 0) in this project and implimentationion.
OpenGL provides three functions glScaled (..), glRotated (..), and glTranslated (..) for applying modeling transformations to a shape. OpenGL also provides functions for defining the view volume and its position in the scene. These functions are used in our design of the house and camera.
Deciding the properties of Light
Some sources, such as a desk lamp, are in the scene, whereas others, like the sun, are infinitely remote. OpenGL allows you to create both types by using homogeneous coordinates to specify the position of the source. So we have (x,y,z,1): a local light source at the position (x,y,z) and (x,y,z,0): a vector to an infinitely remote light source in the direction (x,y,z). Arrays are defined to hold the colors emitted by light sources and are passed to glLightfv().
OpenGL allows three parameters to be set that specify general rules for applying the lighting model. These parameters are passed to variations of the function glLightModel. In order to make the objects in the scene visible even if we have not invoked any of the lighting functions, we set the ambient source to a non-zero value. After we built the light class, we can still move the light sources through translating, rotating and so on.
OpenGL serves two main purposes, to:
1. hide complexities of interfacing with different 3D accelerators by presenting a single, uniform interface
2. hide differing capabilities of hardware platforms by requiring support of the full OpenGL feature set for all implementations (using software emulation if necessary)
In its basic operation, OpenGL accepts primitives such as points, lines and polygons, and converts them into pixels via a graphics pipeline known as the OpenGL state machine. Most OpenGL commands either issue primitives to the graphics pipeline, or configure how the pipeline processes these primitives. Prior to the introduction of OpenGL 2.0, each stage of the pipeline performed a fixed function and was configurable only within tight limits. OpenGL 2.0 offers several stages that are fully programmable using GLSL.
Through the whole process, we now have a good understanding of the computer graphics, how it can be implemented to draw pictures and how the graphics pipeline works.
Rather than “digging” into specific aspect of OpenGL, we tried to present several basic features of this powerful tool. So, if we want to use it to fulfill some goals in the future, we know which aspect we should plunge into. Further effort can be made to a more realistic and beautiful scene with a more powerful camera.
As biomimetic autonomous agents situated in realistic virtual worlds, artificial animals also foster a deeper understanding of biological information processing, including perception, learning, and cognition. For example, they have enabled an advantageously novel, purely software approach to the design of active vision systems, an activity that has heretofore had to rely on mobile robot hardware.
We have been developing an active vision system using artificial fishes and, more recently, artificial humans demonstrating that virtual autonomous agents can support serious
experimentation with image analysis algorithms and sensor motor control strategies. Perception begins with a pair ofvirtual eyes that afford the agent high-acuity foveal vision plus wider field-of-view albeit lower-acuity peripheral vision. With mobile, foveated eyes, controlling gaze through eye movements becomes an important issue. The active vision system includes a stabilization module and a foveation module. By continually minimizing optical flow over the
retina, the stabilization module implements an optokinetic reflex, producing egomotion-compensating eye movements that stabilize the visual field during locomotion. The foveation module directs the gaze to objects ofinterest based on visual models stored in the agent’s brain. For example, a primary visual cue for recognition is color.
Joined: Apr 2012
03-09-2012, 02:48 PM
1OpenG.ppt (Size: 287 KB / Downloads: 36)
Early History of APIs
1973 formed two committees to come up with a standard graphics API
Graphical Kernel System (GKS)
2D but contained good workstation model
Both 2D and 3D
GKS adopted as IS0 and later ANSI standard (1980s)
GKS not easily extended to 3D (GKS-3D)
Far behind hardware development
PHIGS and X
Programmers Hierarchical Graphics System (PHIGS)
Arose from CAD community
Database model with retained graphics (structures)
X Window System
Client-server architecture with graphics
PEX combined the two
Not easy to use (all the defects of each)
SGI and GL
Silicon Graphics (SGI) revolutionized the graphics workstation by implementing the pipeline in hardware (1982)
To access the system, application programmers used a library called GL
With GL, it was relatively simple to program three dimensional interactive applications
The success of GL lead to OpenGL (1992), a platform-independent API that was
Easy to use
Close enough to the hardware to get excellent performance
Focus on rendering
Omitted windowing and input to avoid window system dependencies
Controlled by an Architectural Review Board (ARB)
Members include SGI, Microsoft, Nvidia, HP, 3DLabs, IBM,…….
Relatively stable (present version 2.0)
Evolution reflects new hardware capabilities
3D texture mapping and texture objects
Allows for platform specific features through extensions
OpenGL core library
OpenGL32 on Windows
GL on most unix/linux systems (libGL.a)
OpenGL Utility Library (GLU)
Provides functionality in OpenGL core but avoids having to rewrite code
Links with window system
GLX for X window systems
WGL for Windows
AGL for Macintosh