Tuesday, May 14, 2019
Graphics and Games Essay Example | Topics and Well Written Essays - 1000 words
Graphics and Games - Essay ExampleHowever it has a merit in that the processes involved in generating images be flexible. It is more or less like a graphics assembly language whereby in that location is the possibility of combining the pieces of the softw atomic number 18s hold upality as build blocks to create innovative graphics. Another aspect of the software is that its specifications are not pixel exact. There are high possibilities of two OpenGL unlikely put ining the same graphics. As a result, the software can be implemented in a range of hardware platforms. Exact specifications would go under hardware acceleration, and further its commonplace applicability. In the single implementation, lack of pixel exactness persists. The divergent paths through implementation generate diametrical fragments. Despite this, the specifications do not allow for a set of invariance rules guarantee repeatable actions in various circumstances. Features in OpenGL Features existing in OpenG L are Lighting, Shading, Material and Texture Mapping. This paper will limit its discussion to Lighting and Shading in the programming perspective. Lighting Since light is a science and an art, there are many techniques of creating magnificent light in computer graphics. Through the design of OpenGL software, the lighten arranging approximates light behavior in a simple and efficient fashion. It fits best for computer games since it is possible to render light in real-time. Its lighting does not calculate reflections and scattering of light. At the same time, no shadows are produced. Lighting effects are achieved through textures, shadow mapping and shaders. Practically, light is present everywhere as objects too, react differently in the presence of light. Since light works with materials and has impact when a surface reflects it, OpenGL optimizes on this. Through its functions, it can define the characteristics of surfaces. The definitions focus on what is the color of the surfa ce now? And how much or little light does the surface reflect? These material properties describe surface. The software applies default material set until the programmer specifies his or her own settings. The following are the lighting effects weared by OpenGL directional, Spot, close lights and attenuation. Lighting in OpenGL is defined by the Lighting and Shading models. Before any setting is done, lighting mode is enabled since it requires enabling of the depth buffer. The glEnable is a function that enables several features in OpenGL and one of the features is lighting. This feature becomes the infix parameter but still light will be required. Since the software has a direct support for approximately 8 lights, a light has to be enabled through a call. A disabling function is also available to disable unwanted light functions during programming. During programming, there are two types of light properties to be considered one that describes a light source and the other that de scribes light reflected by the material of an objects surface. This is specified by the function glLightfv. The light attenuation feature is responsible for reducing light rapture in relation to distance. It states the real-world policy that light intensity decreases with distance. During the operation, the position of the source of light must be specified (Ahmed, 2009 pp.1-2). Shading In the shading model, the function call glShadeModel
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment
Note: Only a member of this blog may post a comment.