Help those suffering in the Horn of Africa

A Computer Grahpics courseedxcourse is available at EdX, by Ravi Ramamoorthi, a Professor at UC Berkeley. By the end of the course students should understand the concepts of 3D graphics, and develop programs that create images of a 3D scene with lighting, using both real-time OpenGL and GLSL programming, as well as offline raytracing.

Syllabus:

  1. Overview and Basic Math
  2. Transformations
  3. OpenGL and Lighting
  4. Raytracing

 

udacity

Eric Haines (co-author of Real-Time Rendering) is lecturing an online course at Udacity – Interactive 3D Graphics. The course covers the basic principles of 3D computer graphics, including meshes, geometric transformation, camera definition, lighting and materials, and also animation.

Syllabus:

  • Lesson 1: Introduction - Motivation and a trip down the graphics pipeline, laying out the fundamental processes
  • Lesson 2: Points, Vectors, and Meshes - The basics of 3D geometry definition
  • Lesson 3: Colors and Materials - Color representation, material computations, transparency
  • Lesson 4: Transforms - Translation, scale, rotate and how to properly combine all these
  • Lesson 5: Matrices - Transform representation and how to fully control these
  • Lesson 6: Lights and Cameras - Directional and point light sources, and how the camera is defined
  • Lesson 7: Textures and Reflections - Color and opacity textures, along with reflection and normal mapping
  • Lesson 8: Shader Programming - An introduction to programming vertex and pixel shaders
  • Lesson 9: Interaction and Animation - How to select and make objects move

texturedThe GLSL Core Tutorial has a new section for image texturing. Images are commonly used as wallpaper applied to 3D shapes to create a variety of effects. In this section we focus on the OpenGL and GLSL typical scenario of texture usage, and explore a few new GLSL functions, such as textureSizetextureQueryLod, and textureQueryLevels.

tcBased only on texture coordinates some interesting shaders can be built. In this new section of the GLSL Core Tutorial, a few common shaders, namely the stripes and grid shaders, will be explored. Basic antialising and GLSL functions mix and smoothstep will also be discussed. Source code and a VS2010 solution are also provided.

spotlightThe lighting examples from the GLSL Core Tutorial now include point and spotlights. Source code for all light types, including directional, and shading models, is also available. A VS2010 solution is also provided.

spotlightA new example has been added to the GLSL Core Tutorial showing the theory and implementation of directional lights, using both Gouraud and Phong shading models. Soon more light types, point and spotlights, will follow.

Both FreeGLUT and GLUT allow us to define an OpenGL context with multisampling. However the number of samples is fixed (4) and I’ve not found a way to change it using the API.

In here we’re going to see how to hack FreeGLUT so that we can change the default number of samples. This can be achieved either by changing the default value, or by adding a new function to set this value.

Note: This hack should be used only for testing purposes, not for redistribution, as FreeGLUT has a large base of users which already have the official version installed.

Continue reading »

OpenGL renders to framebuffers. By default OpenGL renders to screen, the default framebuffer that commonly contains a color and a depth buffer. This is great for many purposes where a pipeline consists of a single pass, a pass being a sequence of shaders. For instance a simple pass can have only a vertex and a fragment shader.

For more complex graphical effects or techniques, such as shadows or deferred rendering, multiple passes are often required, where the outputs of a pass are inputs of the following pass, for instance as textures. In this context, instead of rendering to screen, and then copying the result to a texture it would be much nicer to render to texture directly. The figure shows a two pass pipeline, where the first produces three textures that are used in the second pass to compose the final image. This is one of the advantages of framebuffer objects: we can render to multiple outputs in a single pass.

Besides, rendering to screen requires the outputs to be of a displayable format, which is not always the case in a multipass pipeline. Sometimes the textures produced by a pass need to have a floating point format which does not translate directly to colors, for instance the speed of a particle in meters per second.

In this short tutorial we will see how a framebuffer object can be created, and used with shaders. A demo is also provided with full source code, and a VS 2010 solution.

The Lighthouse3D GLSL Core Tutorial has been updated with a few sections, namely how to check the result of the compilation and linking operations, freeing up resources, and how do shaders communicate between themselves on modern OpenGL. The shader interfaces are presented and discussed, with examples and a comparison between the several mechanisms OpenGL provides.

Shaderific is a great iOS application for OpenGL ES shader learning. The app provides the source code for the vertex and fragment shaders for 18 built-in demo shaders, and it allows the creation of new ones. Many 3D objects (including the required teapot) are available, and material and lighting can also be set. There is a free version that lets us try it out, but the changes are not kept once the app is closed.

© 2013 Lighthouse3d.com Suffusion theme by Sayontan Sinha