Jonathan Min Chye's blog

Systems Developer – Specialising in Databases

Browsing Posts in Programming

Came across this code which I think is pretty interesting
int fun(int a)
{
if(a == 1 || a == 0)
return 1;
if(a%2 == 0)
return fun(a/2) + 2;
else
return fun(a – 1) + 3;
}
void main()
{
cout << fun(5) ;
}
What would cout print?
really simple and fun problem

PrintShare

Just created the technical poster for the show case (open day) of my university. I think I did pretty good although any criticism welcomed! Click for bigger versions.

PrintShare

Another coursework. Just playing around and getting familiar with DirectX. Modified an example framework to show Planar shadows, Stencil reflections, with use of shaders (Vertex and Pixel shader) and .X model loading. Just simple transformation of the loaded model as well. The shader used was a standard Phong shader. Was pretty fun!!!
Keys for the demo [...]

PrintShare

One of the courseworks during university is to create an audio only game – targetted at hearing impaired gamers. I think this is indeed a very interesting task. I have created text only game but not audio only game!
Building from a basic framework supplied by the course lecturer, Mr. Allan Milne, I’ve created a simple [...]

PrintShare

I’ve implemented simple Global Illumination (GI) on a heightmap based terrain written using C/C++ programming language and also OpenGL API.
Here’s a copy of my project abstract :

Using Global Illumination (GI) as an advanced lighting method for terrain generation can be challenging and difficult to implement efficiently. Terrain generation normally involves large complex surfaces consisting of [...]

PrintShare
Copy Protected by Chetans WP-Copyprotect.