October 29, 2013
Deferred Lighting: The backdoor, Part 2
In the first part of this article, we covered the a little theory of what this technique means as well as we set the foundations of code that started its execution on main. Now, the functional parts that are needed to create magic are going to be explained as follows.
When the Renderer class is allocated, also the constructor method is called, and here many preparations take place; in the following order: load each necessary CG shader, initialize the sphere lights (8) and place them across the heightmap, create the projection matrix and the root scene node to render objects, load the splash screen as a mesh, and set some configuration of the GCM. It is important to have considered the mesh "Sphere", this object will be the one in charge of draw into the scene the values of each light, in other words, the light will affect only on the area this sphere is colliding with, nothing else, process that differs from a ray tracing procedure. The code for what was explained before is here:
Labels:
C++,
Deferred Lighting,
Development,
GCM,
Nvidia,
Programming,
PS3
October 25, 2013
Deferred Lighting: The backdoor, Part 1
Today, I was asked about the theory behind the Deferred Lighting procedure, of which, to be honest, I was starting to forget (too much Functional programming lately); but what is well learned, is never forgotten.
The main idea behind this technique is to delay as much as possible the calculations of light over the objects on the scene, only those that deserve to be rendered will be performed, otherwise will be discarded. This also relies on "several" passes, which also means, the first time an scene is going to be rendered as normal: vertex positions, its normals and the material for each surface and instead of sending it to the screen it is transformed into a "texture" with information of the depth, normals and specular. This last texture becomes the input for the next step, where lighting takes place using the information from the variables from the previous phase. And then one "last" pass calculates all objects in the scene once again but this time it combines the color from the texture with the emissive and ambient light. The image below shows graphically how they are all added:
Labels:
C++,
Deferred Lighting,
Development,
GCM,
Nvidia,
Programming,
PS3
October 9, 2013
SSH and Sudoers
After I had set up the server to connect to my internet source, the next step to cover was a way to communicate to it without using the User Interface. As there are many solutions, one of the most common, safe and secure is the SSH protocol (Secure SHell).
In order to archive this in the Ubuntu Server, I followed this tutorial:
In order to archive this in the Ubuntu Server, I followed this tutorial:
# sudo apt-get install openssh-client openssh-server
Subscribe to:
Posts (Atom)