Autumn Leaf

Fixing and playing around with things while I am trying to grasp the concept of photon mapping and the k-d tree data structure. I will try to get a working implementation by the end of next week since I have to hand in the fourth progress report.

Below is an autumn leaf that is starting to decay. The textures are by Wojciech Piwowarczyk from his autumn leaves texture pack which sadly does not contain any glossy maps. Unfortunately, he has removed his photo-scanned leaves asset which do contain the geometry for the leaves and all the associated maps.

click the image for full size since wordpress compresses the images.

leaf_all.jpg
Render with diffuse, normal, opacity and translucency map
leaf_translucency.jpg
Render showing translucency
leaf_normal.jpg
Render of just the normal Map
leaf_viewport.jpg
3dsmax viewport; each plane has been successively scaled by 10% and spaced 10cm apart
leaf_test.jpg
An early test of translucency; the front face is white and the back is green
Advertisements

Revision: Software Rasterization

Some more revision for the graphics course. This time I created a software rasterizer using only the information and algorithms described in the lecture slides linked below. Its pretty slow.

In the slides it uses the shoelace algorithm for backface culling and z-buffer for visible surface determination. Below is a screenshot visualizing the depth values; smaller values means an object is closer.

http://www.dcs.kcl.ac.uk/staff/richard/6CCS3GRS/render3d1.pdf
http://www.dcs.kcl.ac.uk/staff/richard/6CCS3GRS/render3d2.pdf

zbuffer.png

 

OpenGL and Qt: part II Cameras and Transformations

I have continued to develop my previous application here by making a camera class. This makes it easy to have multiple cameras, switch between them in the scene and move them about in world space.

The link below goes into details about the transformations used in computer graphics, specifically opengl, and uses the old fixed function pipeline depreciated opengl, but it is still very useful:
http://www.songho.ca/opengl/gl_transform.html

Another awesome resource for learning linear algebra is a website called immersive math.
http://immersivemath.com/ila/index.html

http://www.dcs.kcl.ac.uk/staff/richard/6CCS3GRS/render3d1.pdf
http://www.dcs.kcl.ac.uk/staff/richard/6CCS3GRS/affine.pdf

 

camera.png
Cameras and Transformations

Revision: Bézier curves

Revision for computer graphics course. I created a simple program to play around with bézier curves. I am currently just evaluating the Bernstein basis polynomials directly for the quadratic and cubic bézier curves to determine a point.

I will probably revisit this next week for review and implement De Casteljau’s algorithm since it seems like that is what is being shown on the lecture slides.

The program is written with OpenGL and Qt. The current features include inserting, deleting, selecting, and moving control/anchor points.

 

spline.png
Left Quadratic and Right Cubic

 

Hello, World!

Testing

One, two, three, …

\LaTeX

\frac{a}{c}A_2

Start of my my bachelors thesis, my first step into computer graphics and ray tracing.

#include <iostream>
// comment
int main(int* argc, char* argv[])
{
std::cout << "Hello, World!" << std::endl;
return 0;
}