Sunday, December 28, 2008

Thursday, November 20, 2008

All I Want for Christmas is...

a Ferrari F2008


nah~ I mean a LEGO Ferrari F2008


Yeah, who wouldn't want one of this? I won't even mind hanging around to demolish it piece by piece later on too ;)

During the annual ‘Lego World’ event in Holland, Amsterdam, 12k-20k invested and 80,000 LEGO pieces were put together to create the biggest and most lifelike LEGO F1 car. This Ferrari F1, based on the F2008, is 1:1 scale, which is fully apparently drivable model.

Full story here.

Saturday, November 15, 2008

Minority Report Comes to Life

Oblong's g-speak is the OS that combines "gestural i/o, recombinant networking, and real-world pixels" to creating the dream-OS of every geek's desires.
Ref: http://oblong.com








Wednesday, November 05, 2008

Finger Wiggling Fun

Tuttuki Bako has now made poking something (not dead) actually fun.



Friday, October 31, 2008

Wednesday, October 29, 2008

LittleBigPlanet

I feel that this is one of the coolest game lately out. It may seem like a child's game but its really very creative and hilarious how the objects look like. A little video on the creation of LittleBigPlanet, enjoy~

Here is a video of the game itself,



Sunday, October 19, 2008

Life and How to Survive It by Adrian Tan

Adrian Tan's speech at NTU convocation 2008. I've read his book, The Teenage Textbook when I was a 10 and I found it really interesting the way he wrote it. When I chanced upon this speech he gave this year, I couldn't resist but to pass it along because within it he has expressed several of my own principles in life with words better than I could. Enjoy~ Reference: here.


"I must say thank you to the faculty and staff of the Wee Kim Wee School of Communication and Information for inviting me to give your convocation address. It’s a wonderful honour and a privilege for me to speak here for ten minutes without fear of contradiction, defamation or retaliation. I say this as a Singaporean and more so as a husband.


My wife is a wonderful person and perfect in every way except one. She is the editor of a magazine. She corrects people for a living. She has honed her expert skills over a quarter of a century, mostly by practising at home during conversations between her and me.


On the other hand, I am a litigator. Essentially, I spend my day telling people how wrong they are. I make my living being disagreeable.


Nevertheless, there is perfect harmony in our matrimonial home. That is because when an editor and a litigator have an argument, the one who triumphs is always the wife.


And so I want to start by giving one piece of advice to the men: when you’ve already won her heart, you don’t need to win every argument.


Marriage is considered one milestone of life. Some of you may already be married. Some of you may never be married. Some of you will be married. Some of you will enjoy the experience so much, you will be married many, many times. Good for you..


The next big milestone in your life is today: your graduation. The end of education. You’re done learning.


You’ve probably been told the big lie that ‘Learning is a lifelong process’ and that therefore you will continue studying and taking masters’ degrees and doctorates and professorships and so on. You know the sort of people who tell you that? Teachers. Don’t you think there is some measure of conflict of interest? They are in the business of learning, after all. Where would they be without you? They need you to be repeat customers.


The good news is that they’re wrong.


The bad news is that you don’t need further education because your entire life is over. It is gone. That may come as a shock to some of you. You’re in your teens or early twenties. People may tell you that you will live to be 70, 80, 90 years old. That is your life expectancy.


I love that term: life expectancy. We all understand the term to mean the average life span of a group of people. But I’m here to talk about a bigger idea, which is what you expect from your life.

You may be very happy to know that Singapore is currently ranked as the country with the third highest life expectancy. We are behind Andorra and Japan , and tied with San Marino . It seems quite clear why people in those countries, and ours, live so long. We share one thing in common: our football teams are all hopeless. There’s very little danger of any of our citizens having their pulses raised by watching us play in the World Cup. Spectators are more likely to be lulled into a gentle and restful nap.


Singaporeans have a life expectancy of 81.8 years. Singapore men live to an average of 79.21 years, while Singapore women live more than five years longer, probably to take into account the additional time they need to spend in the bathroom.


So here you are, in your twenties, thinking that you’ll have another 40 years to go. Four decades in which to live long and prosper.


Bad news. Read the papers. There are people dropping dead when they’re 50, 40, 30 years old. Or quite possibly just after finishing their convocation. They would be very disappointed that they didn’t meet their life expectancy.


I’m here to tell you this. Forget about your life expectancy.


After all, it’s calculated based on an average. And you never, ever want to expect being average.

Revisit those expectations. You might be looking forward to working, falling in love, marrying, raising a family. You are told that, as graduates, you should expect to find a job paying so much, where your hours are so much, where your responsibilities are so much.


That is what is expected of you. And if you live up to it, it will be an awful waste.


If you expect that, you will be limiting yourself. You will be living your life according to boundaries set by average people. I have nothing against average people. But no one should aspire to be them. And you don’t need years of education by the best minds in Singapore to prepare you to be average.


What you should prepare for is mess. Life’s a mess. You are not entitled to expect anything from it. Life is not fair. Everything does not balance out in the end. Life happens, and you have no control over it. Good and bad things happen to you day by day, hour by hour, moment by moment. Your degree is a poor armour against fate.


Don’t expect anything. Erase all life expectancies. Just live. Your life is over as of today. At this point in time, you have grown as tall as you will ever be, you are physically the fittest you will ever be in your entire life and you are probably looking the best that you will ever look. This is as good as it gets. It is all downhill from here. Or up. No one knows.


What does this mean for you? It is good that your life is over.


Since your life is over, you are free. Let me tell you the many wonderful things that you can do when you are free.


The most important is this: do not work.


Work is anything that you are compelled to do. By its very nature, it is undesirable.


Work kills. The Japanese have a term ‘Karoshi’, which means death from overwork. That’s the most dramatic form of how work can kill. But it can also kill you in more subtle ways. If you work, then day by day, bit by bit, your soul is chipped away, disintegrating until there’s nothing left. A rock has been ground into sand and dust.


There’s a common misconception that work is necessary. You will meet people working at miserable jobs. They tell you they are ‘making a living’. No, they’re not. They’re dying, frittering away their fast-extinguishing lives doing things which are, at best, meaningless and, at worst, harmful.


People will tell you that work ennobles you, that work lends you a certain dignity. Work makes you free. The slogan ‘Arbeit macht frei’ was placed at the entrances to a number of Nazi concentration camps. Utter nonsense.


Do not waste the vast majority of your life doing something you hate so that you can spend the small remainder sliver of your life in modest comfort. You may never reach that end anyway.

Resist the temptation to get a job. Instead, play. Find something you enjoy doing. Do it. Over and over again. You will become good at it for two reasons: you like it, and you do it often. Soon, that will have value in itself.


I like arguing, and I love language. So, I became a litigator. I enjoy it and I would do it for free. If I didn’t do that, I would’ve been in some other type of work that still involved writing fiction - probably a sports journalist.


So what should you do? You will find your own niche. I don’t imagine you will need to look very hard. By this time in your life, you will have a very good idea of what you will want to do. In fact, I’ll go further and say the ideal situation would be that you will not be able to stop yourself pursuing your passions. By this time you should know what your obsessions are. If you enjoy showing off your knowledge and feeling superior, you might become a teacher.


Find that pursuit that will energise you, consume you, become an obsession. Each day, you must rise with a restless enthusiasm. If you don’t, you are working.


Most of you will end up in activities which involve communication. To those of you I have a second message: be wary of the truth. I’m not asking you to speak it, or write it, for there are times when it is dangerous or impossible to do those things. The truth has a great capacity to offend and injure, and you will find that the closer you are to someone, the more care you must take to disguise or even conceal the truth. Often, there is great virtue in being evasive, or equivocating. There is also great skill. Any child can blurt out the truth, without thought to the consequences. It takes great maturity to appreciate the value of silence.


In order to be wary of the truth, you must first know it. That requires great frankness to yourself. Never fool the person in the mirror.


I have told you that your life is over, that you should not work, and that you should avoid telling the truth. I now say this to you: be hated.


It’s not as easy as it sounds. Do you know anyone who hates you? Yet every great figure who has contributed to the human race has been hated, not just by one person, but often by a great many. That hatred is so strong it has caused those great figures to be shunned, abused, murdered and in one famous instance, nailed to a cross.


One does not have to be evil to be hated. In fact, it’s often the case that one is hated precisely because one is trying to do right by one’s own convictions. It is far too easy to be liked, one merely has to be accommodating and hold no strong convictions. Then one will gravitate towards the centre and settle into the average. That cannot be your role. There are a great many bad people in the world, and if you are not offending them, you must be bad yourself. Popularity is a sure sign that you are doing something wrong.


The other side of the coin is this: fall in love.


I didn’t say ‘be loved’. That requires too much compromise. If one changes one’s looks, personality and values, one can be loved by anyone.


Rather, I exhort you to love another human being. It may seem odd for me to tell you this. You may expect it to happen naturally, without deliberation. That is false. Modern society is anti-love. We’ve taken a microscope to everyone to bring out their flaws and shortcomings. It far easier to find a reason not to love someone, than otherwise. Rejection requires only one reason. Love requires complete acceptance. It is hard work - the only kind of work that I find palatable.


Loving someone has great benefits. There is admiration, learning, attraction and something which, for the want of a better word, we call happiness. In loving someone, we become inspired to better ourselves in every way. We learn the truth worthlessness of material things. We celebrate being human. Loving is good for the soul.


Loving someone is therefore very important, and it is also important to choose the right person. Despite popular culture, love doesn’t happen by chance, at first sight, across a crowded dance floor. It grows slowly, sinking roots first before branching and blossoming. It is not a silly weed, but a mighty tree that weathers every storm.


You will find, that when you have someone to love, that the face is less important than the brain, and the body is less important than the heart.


You will also find that it is no great tragedy if your love is not reciprocated. You are not doing it to be loved back. Its value is to inspire you.


Finally, you will find that there is no half-measure when it comes to loving someone. You either don’t, or you do with every cell in your body, completely and utterly, without reservation or apology. It consumes you, and you are reborn, all the better for it.


Don’t work.. Avoid telling the truth. Be hated. Love someone.


You’re going to have a busy life. Thank goodness there’s no life expectancy."

Tuesday, July 08, 2008

Tetris Has A God

Alexey Leonidovich Pajitnov is a computer engineer from Russian developed Tetris in 1985, while working for the Computer Centre of the Soviet Academy of Sciences. Tetris grew in popularity, appearing on many platforms and styles. Though Alexey may be Tetris' creator and father. Tetris has found its God. At some point of watching this video, I actually thought that the machine will actually blow up but bear with the video and watch on till the end. The player somehow can still manage to play on.



Tuesday, July 01, 2008

Valve: Why the PC is the future by Oli Welsh, 27 June 2008

Original article can be found at Eurogamer.

Valve predicts that the PC is "The" games platform of the future. The PC is often viewed as a multipurpose platform rather then a games platform unlike consoles who's sole purpose are for games. Gabe Newell argues that, "There are 260 million online PC gamers, a market that dwarfs the install base of any console platform, online or offline...PCs remain at the cutting edge of hardware development, and consoles their "stepchildren", in connectivity and graphics technology especially".

Also in games reviews, there are revenues not reported withint the retail charts. Things likedigital distribution, persistence and subscription (revenues of MMO games). With the game that "considered" as the end for PC gaming, is actually the future of PC gaming. Make no sense? Until recently, the fact that World of Warcraft was generating 120 million dollars in gross revenue on a monthly basis was completely off the books," Newell says. "Essentially, [Blizzard is] creating a new Iron Man every month, in terms of the gross revenue they're generating as a studio. Any movie studio would be shouting about that from the rooftops. But it was essentially invisible."

Valve thinks that there's a silent majority of global gamers who are skipping the console era entirely, the way these developing nations already skipped dial-up internet.


Monday, June 30, 2008

The article "So You Want To Be A Game Programmer? How to get out of college and into games" by Matt Gilgenbach and Daniel Sass is a great starting point for the lost souls out there dreaming to be part of the next great game.

They gave four main pointers:
  1. a tight demo.
  2. a clean and professional resume.
  3. some experience.
  4. a pragmatic idea of what to expect.
It pays off to read the article and plan out your actions. To sum it all up, the section on the Demo is really important. The games industry is relatively young and there is a high demand for strong players in the game.
  • Finish your game or demo.
  • Make your demo impressive.
  • Make your demo as easy as possible to view.
  • Do not show off standardized class projects.
Also the last liner is something you should consider seriously.
"If you find math and physics confusing or you aren’t a hardcore coder, then game programming probably is not for you."

Being a game programmer is not the only important role in producing a game. Do some research and find out the role and suits you best. Good Luck~!

Diablo III

The long awaited dream. (May be old news already but...). I've always been a fan of Blizzard because I love RPG (Role Playing Game), I love the fantasy genre, and I love great art word. Blizzard ever so often have delivered all of my loves in one package.

Diablo II released in 2000 was a game college kids play time and again on LAN. It was great fun joining your buddies to battle evil. And we will never forget the secret cow level. The game is all about expending you fantasies, being someone extraordinary that you can't be in real life (like a sorceress), being a hero, and loads more.

So the long awaited dream is the sequel, Diablo III was annouced on the 28th June 2008 and is currently in development right now. Diablo III used the Havok physics engine and loads of new features developed for the StarCraft II. The HUD (Head Up Display) looks like a blend between the original Diablo style and World of Warcraft's icons. The graphics is just so Blizzard. Below are some videos on Diablo III:~


Diablo 3 2008 Movie Trailer Blizzard Worldwide Invitational


Diablo 3 Gameplay Video Part 1


Diablo 3 Gameplay Video Part 2

Friday, June 13, 2008

Greek Drinks

Discovered a new drink from some Greek friends of mine. Its call Ouzo.

First prepare the Raki. Raki (Turkish: rakı, pronounced [raˈkɯ] ) is a non-sweet, anise-flavored spirit popularly consumed in Turkey as an apéritif. First add honey, anise and pure Suma to boil.

Raki = honey + star anise + Suma

Then Ouzo is created by adding some water and the clear spirit becomes white. Ouzo (ούζο) is an anise-flavored spirit that is widely consumed in Greece and Cyprus. Its taste is quite similar to arak/raki in the Levant and Turkey, pastis or absinthe (France), Sambuca (Italy), mastika (Chios). It can be consumed neat or mixed with water.
Ouzo = Raki + water

The drink is drunk hot and it is great during winter with the hint of spicy taste that lingers.

Wednesday, June 11, 2008

My Dream Car

Its been some time since I last posted anything on this site. I've been busy with my semester 2 and currently I'm entering into semester 3, the time I'm going to spend on my Masters Dissertation Project. Well, now with the flexible schedule, I would like to share this cool car from BMW that winks (yeah really~). Thanks Victor for introducing this beauty to me...



Tuesday, May 06, 2008

The Lost World on RobMiles.com

I knew this exists for some time but have not got the time to take a look at it until lately. Rob Miles is one of the lecturers at the University of Hull where I'm doing my MSc Games Programming course. He is also Microsoft's Most Valuable Professional and on the Imagine Cup team. Anyway There is a little photo of me at the end of his journal entry at Return of the Ex Grads. Here is the picture :) if you didn't know, I'm the female on the right.

Saturday, May 03, 2008

AI Programming A*, Mini Max, State Machine

The term AI (artificial intelligence) is sometime confusing and misleading. Artificial intelligence defined by Stan Franklin as "Deciding What to Do Next". Artificial in the sense that we try to simulate real life decision making through technology. Intelligences a property of mind that encompasses many related mental abilities, such as the capacities to reason, plan, solve problems, think abstractly, comprehension, and learning.

One half of my one of my MSc course work is AI Programming. At first I've only a vague idea of what AI is in the software world and now I've a stronger idea of what AI is a wider perspective and also its role in games. From here, my little adventure with Mr. PacMan begins.

The assignment is to write an AI controller for PacMan using any AI techniques available. Researching on AI techniques within a short period of time is almost impossible. What I did was to have an overview and conceptual understanding of most of the techniques and settle on the technique I wanted.

Numerous times you will see me shouting and screaming at PacMan for his idiotic moves or weird behaviors. Asking him to move left, up, right or down like he can hear me or heed my call. Even this assignment seem simple, well its PacMan after all is a game we played when we were 5, yet its really interesting and requires a lot of strategy analysis and behavior study. The one thing I learn is the more I intend to fix it the more I broke the controller. This is because as a human programmer it is difficult to separate behavioral characteristics from my programmer's formulated mindset. Observing PacMan is the way to solve this. Yes, staring at PacMan for hours on end.... But basically this is the skeleton of what I went through...

Development steps
  1. Understanding searches and A* algorithm.
  2. Implementing and independent A* search component.
  3. Heuristic map (cost and total cost) implementation.
  4. Path map implementation.
  5. Techniques to find the goal for PacMan. Outward circular loop algorithm from PacMan.
  6. Mini Max technique from worst case estimate from Ghost.
  7. State Machine for search phases, PacMan movement, hunting mode.
  8. Rules for danger zones in the game.
More information and demo can be found at my portfolio site.

Currently I've an average of 80% win rate, however more data analysis is required.

Imagine Cup 2008

My lame and simple submission. Due to demands of my (more important) MSc Games Programming course projects, we've (Team D&D) have neglected the development of The Lost World.

Flashback, The Lost World is originally a game design assignment for MSc course 08966 Games Development Architectures. We merged our assignment idea to make it The Lost World, the theme more on my teammate's side.

The Lost World is designed to have the old school style video game look and feel with a dash of RPG mode in it. The aim is to have a fun way to educate the player on how to have and maintain a clean and health environment. The main message conforming to the Imagine Cup 2008 theme "Imagine a world where technology enables a sustainable environment".

What we really want to achieve is to relay our message with a simple and entertaining game without bombastic graphics or hardware requirements. The messages in the game is comprehensive yet short and simple for easy learning.

More information can be found at my portfolio site and our Imagine Cup team site.

Here is a video we made for the Imagine Cup and Microsoft Student Partner day on the 5th June 2008 in London.






Some screen shots



Sunday, April 20, 2008

Destroyer

This is my very 1st game I've created. I know its long overdue to post it now but I've just done the video a few days back.

More details can be found at Destroyer

Saturday, April 12, 2008


08968: Advanced Rendering for Games
Battlefield Game Effects
Danielle Cheah
4/11/2008

Online Doc: Battlefield_Game_Effect

To design, develop and implement graphics effects used in a battlefield game by programming the GPU pipeline. Effects are implemented as a set of shader programs in GLSL.

Battlefield Game Effects Left image shows a global view while the right image shows the internal environment view of the scene.


Basic Effects
Textured Terrain with desert illusion is done by creating a sand like noise,
noisy.x = texture3D(sNoise, noiseRate * vPosition).x;
noisy.y = texture3D(sNoise, noiseRate * vPosition + 0.5).x;
combining it with a soft diffuse lighting colour,
float diffuse = 0.3 + 0.5 * dot(vNormal.xy, vNormal.xy);
a grid pattern,
vec2 fp = fract(patternRate * vPosition.xy + noiseScale * (2.0 * noisy - 1.0));
and a little of the environment map,
vec4 color = textureCube(skyBox, vec3(vTexCoord.xy, 1.0)) * fEnvIntensity;


Combat vehicle; Military tank movement is set by
int iTime = fTime0_X;
int modTime = iTime % 10;
float fTime = modTime + (fTime0_X - iTime);
position.x += fSpeed * fTime;
Military tank texture is determined by the density and the noise texture
vTexCoord.xy = fDensity * gl_MultiTexCoord0.xy;
vec4 vColor = texture2D(sNoise, vTexCoord);


Military equipments (grenade, guns, bomb, Barrels) are textured and per pixel lighted.


Flying Shiny air-plane uses basic illuminated reflective surface,
vec3 reflVec = reflect(-viewDir, N);
vec4 reflection = textureCube(sSkyBox, reflVec.xyz);
vec4 refl = fReflScale * reflection;
and rotation matrix for circular movement,
position.xyz = Rotate(x, y, z, fSpeed * fTime0_X, position.xyz);


An animated, semi transparent, reflective water surface. Wave movement (animation) is calculated by combining the wave speed and noise periodic with time
vec3 texCoord = vTexCoord;
texCoord.x += waveSpeed * fTime0_X;
texCoord.z += noiseSpeed * fTime0_X;
vec4 noisy = texture3D(sNoise, texCoord);
vBump = normalize(vNormal + vBump);
Transparent effect is created by using the Blending function. Reflection vector is calculated from the view direction vector
vec3 reflVec = reflect(vViewDir, vBump);
vec4 refl = textureCube(skyBox, reflVec.xzy);
float lrp = 1.0 - dot(-normalize(vViewDir), vBump);


Sky and mountains are done by environment sphere / cube mapping technique by applying the cube map image in the fragment shader,
gl_FragColor = textureCube(skyBox, vTexCoord);


Bumpy brick walls rendered with bump mapping and parallax mapping technique. Left wall is a bump mapped brick wall. Bump mapping is done by perturbing the pixel to the surface normal based on the heightmap.
vec3 N = normalize(2.0*texture2D(sBumpMap, fBumpDensity * vTexCoord).xyz - 1.0);
While the right wall is a parallax mapped brick wall. Parallax mapping has more realism compared to bump mapping due to the displacement of the texture coordinate from the view direction in tangent space. The tangent matrix,
mat3(vTangent.x, vBinormal.x, vNormal.x,
vTangent.y, vBinormal.y, vNormal.y,
vTangent.z, vBinormal.z, vNormal.z);
Finding the displacement,
vec3 V = normalize(vViewDirection);
float Height = scale * texture2D(sWallHeight, vTexCoord).x - bias;
vec2 TexCorrected = Height * V.xy + vTexCoord;


Fire and smoke with particle systems, bill-boarding techniques, and alpha blending. Particles are crated, looped and changes color it a timely fashion
float t = fract(gl_Vertex.z + particleSpeed * fTime0_X);
vColor = 1.0 – t;
Particles are randomly positioned based on the particle system attributes of particleSpread, particleSystemShape, and particleSystemHeight. Bill-boarding is done by transforming the position based on the ViewMatrix
position += particleSize * (gl_Vertex.x * matViewTranspose[0] + gl_Vertex.y
* matViewTranspose[1]).xyz;
Alpha blending is done by introducing a fade coefficient to the gl_FragColor
float fade = pow(dot(vTexCoord, vTexCoord), particleShape);


Explosions rendered with particle systems and bill-boarding techniques. Explosion effect has additional attribute in terms of a latitude distribution of the particles
float theta = asin(vel.z / radius);
vel.x = particleSpeed * radius * cos(theta) * cos(phi);
vel.y = particleSpeed * 2.0 + abs(particleSpeed * radius * cos(theta) * sin(phi));
and a longitude gravity pull of the particles
pos.y -= (0.5 * fGravity * dTime * dTime);
also the explosion is time controlled to explode at certain periods.


Animated battle flags rendered using some advanced anisotropic illumination technique. Flag animation is by translating the z value of pixels with sin(y) and sin(x) functions
position.z += sin(position.x / 4.0 + angle) * fWaveScale;
position.z += sin(position.y / 4.0 + angle) * fWaveScale / 4.0;
Multiplying again with x value will fix one side of the flag in position
position.z *= (position.x - 14.0) * 0.02;
The normals are calculated by using the same formula applied to x and y values. Anisotropic lighting is used to express micro-faceted surface like cloth fibres. The method used is the Heidrich-Seidel anisotropic distribution based on the Phong reflection model.
Where n is the specular coefficient, L is the light direction, V is the view direction, and T is the tangent space normal. Similar in shader code,
float specular = pow(clamp((cs * cl + sn * sl), 0.0, 1.0), fSpecular);
Getting the tangent space normal
vec3 tang = sinA * vTangent + cosA * vBinormal;


Animated tongue of fire jetted from the tail of a flying fighter plane. Air-plane’s tongues use a particle system, bill-boarding technique, alpha blending, and rotation matrix for circular movement.


Sand clouds generated from vehicle wheels. The sand cloud uses a particle system, bill-boarding technique, and alpha blending techniques. The sand cloud movement is following the tank's time and speed. An additional face coefficient is introduced to produce a finer blend colour.
float fade2 = vPosition.y / particleSystemHeight;


Optional Effects
Shadow effects.
Self casting shadow effect on oil tank. Using the projected vector to create the shadow map
vProjShadow = gl_TextureMatrix[1] * position;
color *= shadow2DProj(sShadowMap, vProjShadow).r;
A blend coefficient is introduced to determine the weight factor for the shadow intensity and blending.


Shadow mapping of air-plane onto terrain. An air-plane image is rendered to a Renderable Texture Target and is combined with the terrain colour. vec4 shadowColor = texture2D(sShadowMap, vTexCoord);
gl_FragColor = finalColor * shadowColor;
The top-left image shows direct blending of the shadow map onto the terrain. The top-right images shows the shadow map blended onto the terrain through the transparent water. The bottom image shows the movement of the shadow following the shiny air-plane.


Ray traced reflection (change in vector direction between two different media so that it returns to the media it originates) and refraction (change in vector direction to a change in speed between two different media) effects from shiny and transparent objects in the battle field, such as glass balls (surveillance balls). Two rotating surveillance balls, one yellow transparent surveillance ball and one solid orange surveillance ball; Left image shows both surveillance balls with reflective attributes and the right image shows the yellow transparent surveillance ball with refractive attribute. Both balls are shaded using the Phong Lighting Model and shadow rayed. A ray is used for reflection and refraction each. Both rays are cast forward in world space to get the 1st hit point of the sphere. For solid objects, the reflection ray is cast forward again from the hit point using the new direction vector. For transparent objects, the reflection and refraction rays are both cast forward again from the hit point using the new direction vector. Direction vectors are found using the reflect() and refract() functions. Three passes are conducted. Each pass will check the object it is currently rendering to set the respective transparency value.


Additional Features (Other novel effects added to increase the realism of the battlefield)

Specular glitter on bomb is done by creating a grid pattern and perturbing it with a 3D noise texture and the view direction for directional glitter effect.
vec3 fp = fract(0.7 * vTexCoord + 9.0 * noisy + 0.1 * vViewDirection);
fp *= 0.5 * (1.0 – fp);
float glitter = clamp(1.0 - 7.0 * (fp.x + fp.y + fp.z), 0.0, 1.0) * 10.0;
Glitter only appears around the specular highlighted and spreads out based on the spread coefficient.


Anisotropic brush metal effect for water tower uses two light direction vectors (original light direction and a –x light direction) to determine if the isotropic highlight occurs. The actual anisotropic direction vector is determined from the dot product between the normal and the ring properties in texture space coordinates. Strand Pair Lighting Model is used to merge both light diffuse and specular colours. For each light direction, the specular colour is power two of the corresponding y value of the 2D texture. The diffuse colour is the corresponding x value of the 2D texture. The (x, y) from the 2D texture is determined from, float LdA = dot(light, dirAniso);
float VdA = dot(view, dirAniso);
vec2 fnLookup = texture2D(sStrand, vec2(LdA, VdA) * 0.5 + vec2(0.5,0.5)).xy;
This lighting model also has self shadowing based on the light direction and vertices normal,
float selfShadow = clamp(dot(normal, light), 0.0, 1.0);


Noise and pattern generation on objects like the wood grain pattern on the saw horse shown in the left image; and the molded grid pattern on the camouflaged gate shown in the right image. The wood grain pattern is created using three different matrixes (three different texture coordinates) to generate three different noise values. The Noise values are added to a frequency scale and blended into the 2D texture.
vec2 scaledDistFromZAxis = vec2(sqrt(dot(vNoisy.xy, vNoisy.xy)) * fFrequency, 0.5); float fBlend = texture2D(sPattern, scaledDistFromZAxis).x;
The grid pattern is created using the fract() function to combine the noise value from a 3D texture with the pattern frequency.
vec2 fp = fract(fPatternRate * vPosition.xy + fNoiseScale * (2.0 * noisy - 1.0)); fp *= (1.0 - fp);


Multi-texturing masking mapped metal bridge uses a mask texture r value to discard the vertice of the original textured surface.
vec4 TexCol = texture2D(sBridgeBase, vTexCoord);
float maskVal = texture2D(sBridgeMask, vTexCoord).r;
if (maskVal < 0.6)
gl_FragColor = (vAmbi + vDiff + vSpec) * TexCol;
else
discard;


Polynomial texture map lighting for tablet wall. The light direction is dependent on the tangent and binormal values and extending the light depth of z direction. From the higher order term, x² + y² + xy, get the two alpha values from two different alpha representation textures.
vec3 lu2_lv2_lulv = nLight.xyx * nLight.xyy;
Merge the colours and discard any out of range values.
vec4 color = vec4(dot(lu2_lv2_lulv, a1) + dot(nLight.xyz, a2));
color = color * texture2D(sBase, vTexCoord);
vec4 maskVal = texture2D(sBase, vTexCoord);
if (maskVal.r>0.2 && maskVal.g>0.2 && maskVal.b>0.2) gl_FragColor = color * 2.0 + + 0.1 * texture2D(sTerrain, vTexCoord);
else
discard;


Combat helicopter with Mandelbrot fractal effect. Fractal is a repetitive smaller representation of an original pattern, a property of self-similarity. Using the superset of “C” is the subset to be colored as part of the Mandelbrot pattern. Mandelbrot has a cardioid region in the center, “c”, each has a bulb attached to it. Each bulb consist of the “C” parameter for which the hyperbolic components, maps to another P component. Implementation include getting the real and imaginary values from the fractal zoom view and the center point, “c”.
float real = vPosition.x * fZoom + vCenter.x;
float imag = vPosition.y * fZoom + vCenter.y;
Loop to populate the Mandelbrot,
for (iter = 0; iter < 15; ++iter)
{
float tempreal = real;
real = (tempreal * tempreal) - (imag * imag) + cReal;
imag = 2.0 * tempreal * imag + cImag;
r2 = (real * real) + (imag * imag);
}
The Mandelbrot, “C”, is colored based on the loop iteration (either foreground or background color).

Tuesday, March 18, 2008

Physics the Law for Everything that Exists

The title is purely my opinion and is not based on any theoretical finding that someone else had done.

I've a passion for programming, games and figurine collection. These combined made me interested in AI robotic programming and games programming. I've decided to focus more on the software side and go for games programming. AI robotic programming will be my part-time hobby when I feel like playing God and giving birth to a plastic/metal based artificial life.

During my research into jobs in the games industry and my latest Open Day visit to Frontier Developments in Cambridge (Yeah~! being shortlisted is not bad for a noob :)). I've noticed in the games development industry there are several areas of interests, mainly (my categorization); game play development, engine development, resource development, tools development and misc.

Game Play Development
This is where the actual storyline is incorporated into the game. Where the engines are merged together and the game design forms. Most often, the AI is developed as part of the game play because it makes more sense to have a custom AI for each game rather then a mighty AI brain engine to solve all possible problems.

Engine Development
There is a list of engines that are usually developed like the graphics engine, physics engine, network controller (if any), etc. Engines are like standalone components that are usually reused and built upon as each title is developed.

Resource Development
This is where audio, graphics designing, models, texture, etc. are produced which will be the final game's outlook and representation that players see.

Tools Development
Tools are developed mainly to cut down resource development time. Tools include customized and user friendly modellers, audio generators, designing tools, CAD, etc.

My Take
While working on my projects and specific job position hunting, physics modelling and simulation caught my eye. Its really fun to figure out how things work and react with each element that effects it. It is extremely hard to understand and figure out new techniques to solve each problem, but as the fundamental understanding is instilled, the solution comes easily.

The potential of growth and knowledge in the games development is huge if not infinite. I'm eager and looking forward to contribute and to the industry.

Sunday, March 09, 2008

Dissertation Project Proposal


Group Members
Danielle Cheah, Ding Loong Wei


Title
A 3D immersive environment for a paintball game using the Wiimote.


Gameplay objective (Paintball)
Paintball is a sport in which player(s) eliminate opponent(s) from play by hitting them with balls of paint shot out from an air pressured gun. Players are divided into two opposing teams within an area of terrain. The aim of the game is to capture the flag by move forward towards the opponent(s)' side and reach the flag area or killing off all opponent(s). The first team to capture the flag is the winner.



Project Abstract
A single player paintball training system against an AI opponent. The gameplay area will consist of the player, AI opponent, air pressured paintball gun, obstacles for cover and target objective/flag area. Using the Wiimote and infrared emitters for player head tracking and positioning within the game. Another Wiimote as the point and shoot input device as the air pressured paintball gun. Consideration to have Nunchuck as the player's forward and backward movement. The AI will try to path trace and move forward to capture the player's flag. The AI will try to take down the player by firing at the player and dodge or hide when being fired at. In turn the player should do the same before the AI captures the player's flag. Effects includes physics for gun recoil and impact on target with external factors (speed, external forces, wind, etc).


Section Allocation
Student 1: Wiimote system & graphics
Student 2: AI & physics


Considerations

  1. May allow user to choose between several types of weapon (air pressure gun, padded arrows, slingshot, etc.).
  2. Physics based on different weapon type (speed, external forces, weapon weight, etc.).
  3. Network technology to have player vs player.

Tuesday, March 04, 2008

C++: Using string in switch

This is just a code snippet of how to use strings in switch in C++ which is taken for granted in C#
enum Config
{
SolidBall
};
std::map ‹string, Config› _mapStringConfig;
void Main()
{
switch(_mapStringConfig[str])
{
case MainProgram::SolidBall:
break;
}
}

Wednesday, February 27, 2008

Imagine Cup France 2008

For one of my modules for game architecture, there was an assignment for game design. Game design is basically to design the game in the sense of the game machanics (how the game is played), storyboard (the game's story line and flow), game message and mission. A part of this assignment was to design a game based on the Imagine Cup rules, regulation and theme. Also to create a playable verticle slice of the game.

My teammate and coursemate also did the same. We kindda merged our ideas and created team D&D (being our initials). Team D&D summited a game titled The Lost World.

The Story
The Lost World sets the world at the time where earth has gone through decades of revolution. However, human being who lives on this planet did not take a good care of their mother earth. In Year 2009, the pollution on this planet earth has reached its limit. It caused half of human population died. Besides, this bad environment has makes animals facing their extinction.

While most of the human being on Earth cares only their money and their entertainment, there are a bunch of people out there that really cares about their mother Earth. Ken, a world famous scientist who specialized in researching for methods to make the environment sustainable is attending Earth Summit Conference together with his researcher.

There is an isolated island that still keeping the beauty nature of this planet. It keeps hidden from the rest of the world by using a high-tech semi-sphere force field. This thanks to the scientists who live on this island. The technology and the attitude of the residents have made this island free from any kind of pollution. However, civil war has put them into trouble and caused most of the resident died.

The Game Design

Sunday, February 10, 2008

Saturday, February 09, 2008

Wiimote Projects

I'm conducting some background research on the Wii System particularly in the Wiimote development area and this is a list of projects on the Wiimote currently available.

Wiibot by uTouch which uses 2 Wiimotes to control the movements of the Aibo.


World Wind Wiimote VR by Nigel Tzeng which uses 1 Wiimote as the receiver and a bluetooth device for the head tracking to navigate in the World Wind environment.


Wii Data Visualizer by Matthias Shapiro is a visualization system that displays the information gathered from the Wiimote.


Blue Tunes by Mike Anderson is a simple comtroller system which utilizes the Wiimote to control audio players on the PC.


Wiimote Drum Kit by Evan Merz which uses 1 Wiimote as a drum stick in combination with button press to indicate the drum set.


Wiimote Guitar by Evan Merz which uses 1 Wiimote as the whole guitar with button press as the cords and the hand strokes as the strumming motion.


Project Maestro by Cynergy Labs uses a Wiimote to receive movement and action from Infrared gloves that the user is wearing.



Reporting a CT scan using GlovePIE. GlovePIE is by Carl Kenner which is an input library for many devices.


Virtual Patient Project by Brent Rossen

WiiEarth - Wiimote Interface for Virtual Earth by Brian Peek

A Wii Flock of Boids - Integrating the Nintendo Wii Controller with XNA by Rob Burke

Wii Presenter by Chad Hower

GiiMote for Game Maker by Leif Greenman

Friday, February 08, 2008

The Pre-Wii Brainstorming Session

Before the birth of Wii, back in 2001, little Wiimote & Nunchuck were one and they were known by a single name the GyroPod. This was the prototype created by Gyration for Nintendo (Gyration is a company with the most motion-sensing patents. Nintendo listensed some of these patents and later became Gyration's investor. The design was meant to break loose from the standard two handed controller - also the consideration of left-handed usage.
Wii, then codenamee "Revolution", was all for a unique game interface and that power was not everything like most major consoles were heading towards. Anyway, it was impossible to build a powerful machine for less than 50,000 yen ($450 - intial target). It use a lot of electricity, need a fan, increase noise, too long to boot up and lost its identity as the ideal toy (behaving more like a PC).

After thinkering with previous Nintendo gadgets, DS's touch screen and GameCube technology; some mobile devices,
cell phones and car navigation remote controllers; Nintendo wanted something new and to change the interface would broaden game design and loosen creative constraints on programmers. Then came the controler's wireless technology; infrared pointer, pointer's precision and mimic 3D space recognition.
Some technical information about the Wiimote:~
  1. Wii-mote will operate for 60 hours on two AA batteries
  2. Communicates via acceleration detection, force feedback and Bluetooth technology on a 2.4GHz band
  3. A 6KB of "non-volatile" memory
  4. An internal speaker
  5. A SYNCHRO button to assigns each controller a wireless ID number
  6. Two infrared transmitters on the sensor bar (which this infact is useless as it only emmits 2 light source, these light sources can be replaced with any light source pair to guide the orientation of the Wiimote - the pairs behaves like the mouse cursor but in a paired format forming a line where it may show the tilt of the Wiimote)
  7. A LED to show which player is communicating with the console at a given moment and to show battery life
  8. A built-in rumble motor
  9. Act as an eye, measuring coordinates between 0-1023 on the X axis and 0-767 on the Y axis similar to megapixel image coordinate system.
Wii was all about a new form of game play for consoles. It did not try to overpower or outperform other consoles in terms of processing, graphics or the sort. All Wii is about is to be a low cost way to deliver the ultimate gaming experience to all forms of gamers (pro-gamers, non-gamers, casual-gamers, etc.). Its really cool how simple existing technology is meshed together to have a whole new experince, thus not needing huge chamber like equipment in your living room to have a simulated 3D emersive environement. Also, its pretty cool how just using the Wiimote automatically makes the player react and manoeuver in a natural bodily motion when reacting to the simplest game.

This is where I feel that game development effords would go more to the playablity of the game, game design, fun factor and creativity in using the Wiimote(s). While there are other console platforms to grow game development skills in the hardcore technicle side, Wii provides a broader horizon for creative ideas to come into games development.

Monday, February 04, 2008

2008 Game Lineup

2008 is a year of many promising titles that any gamer will enjoy (at least I would). Over 300++ titles, I've finally came up with a rough list of those games, release dates and some info. Feel free to check out the full list at my published spreadsheet. Also drop me a comment if I've got any info on the list wrong. Here is Febuary's list. Enjoy~

Sunday, February 03, 2008

Best Anime of 2007

Another year has gone by and Japan has its call out for the top animes of the year. Reported by Yahoo Japan, over 2 million Japanese anime fans voted for their fave anime of 2007. The top 10 out of 100 titles where as follows. For English discription on the below anime, visit AnimeNewsNetwork.
  1. Sola
  2. Lucky Star
  3. Katekyo Hitman Reborn
  4. Ookiku Furikabutte
  5. Higurashi
  6. Gintama
  7. Nanoha StrikerS
  8. Nanatsuiro Drops
  9. Sayonara Zetsubo Sensei
  10. Hidamari Sketch
One that I like

Saturday, February 02, 2008

Computer Science Education: Where Are the Software Engineers of Tomorrow?

This is an article snipnet from Software Technology Support Center. I feel that this is a good article to think about where software development is heading to in the future.

In the article mentioned that there is a downward thrend of software skills developed during degree years;
  1. Mathematics requirements in CS programs are shrinking.
  2. The development of programming skills in several languages is giving way to cookbook approaches using large libraries and special-purpose packages.
  3. The resulting set of skills is insufficient for today’s software industry (in particular for safety and security purposes) and, unfortunately, matches well what the outsourcing industry can offer. We are training easily replaceable professionals.
Education is neglecting basic skills, in particular in the areas of programming and formal methods, exposure is model checking and linear temporal logic for the design of concurrent systems and floating-point computations.

Because of its popularity in the context of Web applications and the ease with which beginners can produce graphical programs, Java and scripting languages has become the most widely used language in introductory programming courses. When Object-Oriented programming is introduced in early education, students found it hard to write programs that did not have a graphic interface, had no feeling for the relationship between the source program and what the hardware would actually do, and (most damaging) did not understand the semantics of pointers at all, which made the use of C in systems programming very challenging.

A real programmer can write in any language (C, Java, Lisp, Ada, etc.). The study of a wide variety of languages is, thus, indispensable to the well-rounded programmer. A well-rounded CS curriculum will include an advanced course in programming languages that covers a wide variety of languages, chosen to broaden the understanding of the programming process, rather than to build a résumé in perceived hot languages.

Students need to be exposed to the tools to construct large-scale reliable programs, as we discussed at the start of this article. Topics of relevance are studying formal specification methods and formal proof methodologies, as well as gaining an understanding of how high-reliability code is certified in the real world. When you step into a plane, you are putting your life in the hands of software which had better be totally reliable. As a computer scientist, you should have some knowledge of how this level of reliability is achieved.

Wednesday, January 30, 2008

Mac Book Air

Yeah as part of the "Techie" society, again I'm being fooled by Apple's lastest gadgets. Just a while back (1/10/2007) when the iPhone was shipped, I couldn't help myself but to drop by the nearest 02 to get a feel of the sweet thing.

Then the new IPod Nano came along, being this cute irresistable thing that can fit into my slim wallet, its just the thing I love just looking at. Its not something I need but just something that cute that I like. With video capabilities it looks like the baby version of the IPod Video.

But browsing the web few weeks back make me want another Apple item...The Mac Book Air.

Yeah at 1.94cm thick and weight at 1.36kg you might think what the hack can it do? And with a Intel Core 2 Duo processor, I wonder how did they even put in a decent fan. The higher end of the Mac Book Air, it also has all the common stuff on any laptop, 2GB RAM (on board), multi touch trackpad, Intel GMA X3100 144MB shared memory, etc. But at a price of £1,199.00 / £2,028.00, you are most likely paying for the coolness of having something "IN" for the times.

Here are some videos on Mac Book Air's intro at Mac World 2008...


Monday, January 28, 2008

LEGO® “Toy of the Century”

January marks the passing of LEGO® half a decade of fun play. LEGO bricks was nomiated as the "Toy of the Century" by both Fortune Magazine in the US and the Britsh Association of Toy Retailers.

The History
1932, Ole Kirk Christansen founded a small factory for wooden toys in Billund in the south Denmark. LEGO is a fusion of the Danish words “LEg” and “GOdt” (“play well”).
1947, Christiansen discovered plastic as the ideal material for toy production, and bought the first injection moulding machine in Denmark.
1949, he developed the LEGO brick prototype.
1963, production of LEGO bricks with Acrylonitrile Butadine Styrene (ABS) began.

The Bricks
There have been adjustments in shape, colour and design from time to time, but today’s LEGO bricks still fit bricks from 1958. LEGO bricks are produced in special plants in Denmark, the Czech Republic and Mexico. The ABS compound is delivered in granules, which are heated to 232° C until they melt. Injection moulding machines (weighing up to 150 tons) presses the hotplastic mass into LEGO brick shapes and is left to dry and harden. Each injection mould is permitted a tolerance of no more than one thousandth of a millimetre, so that bricks of every colour and size stay firmly connected. There are 2,400 different LEGO brick shapes. LEGO bricks in boxes that are not sold are melted again and turned into new bricks, in accordance with waste prevention and environmental responsibility.

What I really wanted to talk about
LEGO® MINDSTORM® is made up of several main components the NXT (the brains), touch sensors, sound sensors, light sensors, untrasonic sensors (detects distance), and servo motors (for movement). There are several development areas that basically lets you go into robotics without any skillsets. Areas to explore
  1. NXT firmware development for the ARM7 ATMEL microcontroller and the 8-bit AVR ATMEL microcontroller.
  2. Software development using SDK. The software controllers can also be easily developed using LabView, NBC (Next Byte Codes), Microsoft Robotics Studio, and Gostai URBI for LEGO Mindstorms NXT.
  3. Custom hardware development using HDK. Mindstorm competible hardware are HiTechnic Products and Mindsensors.
  4. Custom hardware communication development using BDK (Bluetooth Development Kit).
Getting started with some of MINDSTORM's robots with blueprints and guides. Meet the robots;
Alpha Rex (Humanoid) has sight(an ultrasonic sensor), hearing (a sound sensor), voice(a built-in Speaker on the NXT brick and sounds from the NXT Software), mobility (2 servo motors) and sense (touch and light sensors).

Spike (Insect Scorpion) has movement (six legs), a set of pincer arms (pedipalps), sight(an Ultrasonic Sensor) and hear (a sound sensor) and attacks with its stinger (a touch sensor).

RoboArm T-56 (Machine) can lift, pivot, and grab objects with its claws. It can detect colors (a light sensor)feel objects (a touch sensor) arm mobility (3 servo motors - 1 for the grabber claws, 2 for the robotic arm to move up, down, and turn).

Tribot (Vehicle) can grab a ball when you give it a sound command (a sound sensor), move following a line (a light sensor), feel objects (a touch sensor) and see objects(an ultrasonic sensor).

I think this is really a cool toy to get for any child. I'm thinking of getting one (heh...). However it does cost GBP179.99 (estimate RM1155.52)