Skip to main content

Shader OpenGL Library

OpenGL Library implemented with shaders!

Ian Mallett

My first OpenGL Library uses fixed function OpenGL, which is all very well and good, unless you want to do anything complicated. That's where this comes in. It is still in heavy development, but already it has some nice features:

1. .obj file Loading:
     -Efficient and fast optimizations
     -Vertex arrays
     -Automatic texture handling
     -Automatic tangent vector calculation
     -A triangle, cube, and spaceship .obj files included
2. A few built-in primitives
3. 7 prebuilt shaders including:
     -Flat color shading
     -Material shading
     -Texture shading
     -Depth buffer visualizer
     -Blur shader (see 4.)
4. Semi-realtime blur
     -Two pass for speed
     -Linerly seperable box filter
     -Variable kernel sizes
     -Pseudo-gaussian kernal distributions
5. Fully Customizeable Shaders
     -Abstracted, yet fully-featured programmer interface
     -Customizeable variables
     -Customizeable vertex transforms
          -Realtime mesh deformation
     -Customizeable texture coordinate transforms
     -Customizeable rendering equation
          -Parser optimizes
          -Parser adds complicated code when needed only
     -Built-in functions including:
          -Texture mapping
          -Normal mapping
          -Parallax mapping
     -Extendable with user-specified functions
     -Phong (per-pixel) shading model is standard
     -Automatic error logs
     -Integrated support for up to 5 lights on all effects
6. 28 built-in materials including:
     -Metals, such as gold, silver, and copper
     -Gemstones, such as emerald, jade, and ruby
     -Pastics in many colors
     -Rubbers in many colors
7. A demo
8. Reflection/refraction and shadows coming soon!

The whole thing is, of course, free, so long as no one tries to pass this whole thing off as theirs.

No tutorials yet, due to the "beta" nature of this project. The demo, which can be eaily modified to create these screenshots, shows normal mapping and parallax mapping to good effect. See the title bar on top for the controls. The screenshot on the top left is a normal map with a gold material, the top right is the same object with a different normal map and parallax mapping, and the bottom is a cube's face with yet another normal map.

NOTE: there are some known pending issues with this library on some ATI cards. I'm fixing them ASAP. Most NVidia cards should be fine.




Home Page


Shader OpenGL Library 3.4.7 — 7 Dec, 2008 account Comments

  • jhonphilipps 2013-04-05 11:27:05

    I like it, i'm student in blender, i'm trying hard to make parallax effect for my school project ! THX for you're help :)

  • Zhanrui Liang 2014-01-04 12:45:25

    The code let pyOpenGL to convert data from python lists to ctypes array at each frame, so rendering is very slow. After changing this, it runs much faster.