Page 10/36
Components
This chapter is divided in four parts describing four groups of GLScene components: GLScene,
GLScene PFX, GLScene utils and GLScene shaders.
GLScene
GLScene
The basic component. You can open GLScene editor by double clicking on it.
GLSceneViewer
The scene viewer represents a rectangular canvas where the scene gets rendered. It's size or
width length ration is not restricted. The bigger the viewer the slower the rendering will be. You
must specify Scene and Camera properties. Change important rendering context through Buffer
property. However leaving Buffer default properties will suffice in most cases.
GLFullScreenViewer
Same as TGLSceneViewer but switches to fullscreen mode. The resolution has to be
readable for the graphics card and monitor. So it should be something like 800 x 600 or 1024 x 768.
GLMemoryViewer
Memory viewer is a virtual canvas. You can render on it, read its output from the memory.
But you can not see any picture on the screen. It is used for example for rendering cube maps for
real time reflections or more advanced shadow techniques.
GLMaterialLibrary
Material library is a storage component for materials. It has collection of materials and you
can access individual materials by index or the material name.
At this point I should explain something about how materials are handled in GLScene. Each
object where material is applicable has its Material property. You can edit materials directly in
object inspector or double click on the ellipsis icon next to material and open material editor.
Material editor has three tabs and a window with an example cube textured with current material.
The three tabs are:
1. Front properties edit material quality of objects front faces. Diffuse color being the most
important. It defines color of the object on direct light. Ambient color defines the color of
object in dark spots. Specular color is color of high reflections and shininess defines how big
those reflections are. Emission color makes the object glow. But for now just remember that
to change objects basic color use diffuse color. Other material qualities like reflection and
shininess can be achieved more realistically with material shaders.
GLScene beginner's guide, Jan Zizka, 2005