Posts Tagged ‘INFR3110’

Seems I am falling behind on posts for Game Engines! Well here’s another update on my progress in the past couple of hectic days.

As for homework questions in the course goes, last week was a race to program and figure out the process of making a detailed solar planet model for a medium ranked question in the course.

The application had to show accurate planet rotations, orders, moons and when you clicked on the planets it had to show a HUD full of good ol’ info about the planet.

What I learned:

The main goal/purpose of this assignment question was to learn how to parent objects effectively (scene graph) and learn how to use Ogre3D’s ray casting functions.

How it looked:

Here is how my solar planet looked. Yes I know the Sun is too small. But oh well. I’m not an astronomer! I’m a programmer! 


For parenting, it was actually pretty easy. Every planet and moon needed to have it’s own node for the object to be drawn/attached to in addition to being a child node to a node that it would rotate around.

Moons would be parented (be children of) the planet they would orbit, and have their own node for the sphere to be drawn and textured. The planets would be children of the root node, which is the center of the solar system (the Sun).

Now, I made the mistake of making the Sun itself the root node at first. Why is this a problem you may ask? Well you see, if I made any changes in scale, rotation or position to the Sun, it would result in changing the attributes of all of the root node’s children. So if I scaled the Sun bigger, it would make all the other planets bigger too!

So in the end I learned I needed to attach the Sun separately.

Ray Casting:

In order to be able to select an object, I had to learn how to ray cast in Ogre3D. What this is is essentially a ray is shot from the cursor of your mouse into the screen. The cast will give you back whatever object it hits. Thankfully there is a build in iterator which helps you sort out the objects, and essentially find the object that is closest to you, which is what you want, since you want to select that object and not an object behind it.

This is a useful function to learn because it teaches us how to select an object, and discard any information about object selection with objects you do not want.

Midterm Summary/Reflection

This recent Monday, we had our Game Engine Design midterm. So how’d it go?

I believe I did okay. Not the best, but I certainly hope I passed! What would I have changed in preparation for the midterm? Studied more! Read all of the textbook chapters! I was crunched for time and did not read up on all the stuff I should have. After the midterm I started reading, and sure enough the next couple pages covered some questions in the midterm that I didn’t know how to answer!


So a good tip to my fellow students; READ THE TEXTBOOK! It really does help (for the stuff I did manage to read, I managed a great understanding of those concepts)


Also, brush up on your matrix/quaternion math. You should know that stuff all the time. Especially inverses.

Success! Over the end part of September and beginning weeks of October, I have started catching onto how to use Ogre3D and TwoLoc. Contrasting my first blog post for INFR 3110, I really am starting to get the hang of programming with this engine.

The feeling of being able to finally create something of my own is great, and motivates me to strive to learn more and create more complex things. At the end of working furiously, I have come out with 4 products (easy questions) that function as requested!

Easy Question 1:

The first step to programming in TwoLoc was to load a textured model. For this question I leaned towards Ogre3D’s preferred model file type, a .mesh file. I also discovered that after exporting a .mesh of an object, a .material file accompanied it. I also discovered after a long while of tinkering, all names of materials are listed in the material file. After ironing out a few details I was presented with a textured model! Success!

Easy Question 2:

Question 2 was a robot arm! Create a working robot arm with movable portions similar to a real robot arm. This question taught me about creating entities in TwoLoc as well has parenting nodes, offsetting nodes and all sorts of useful things. Oh and keyboard input control!

Question 4:

This question was to create a tree using billboards and impostors. It took a while to do, simply due to confusion on what the question wanted. But the product is a very low poly count tree that can be used in game!

Question 6:

In this question, we had to create a skydome. The skydome also rotates around the world plane with an update that is called where it increments its rotation around. I think it looks pretty neat, and overall was actually pretty simple. Another useful thing that can be applied to this year’s game.


Overall it’s been a pretty hectic month trying to learn and complete these items. But hey it’s part of the learning process. Hopefully things keep on chugging along smoothly!

Feeble Attempt with TwoLoc and Ogre3D

Posted: September 30, 2012 in INFR 3110
Tags: ,

Over this weekend, me and my group sat down and tried to tackle the TwoLoc engine provided for this year. We tried to figure out how it worked and how to make it do what we wanted it to do. I will be going through my experience through it this weekend.



It sucked.



Yea I know I shouldn’t whine about it, but seriously. I’m not trying to say TwoLoc or Ogre3D sucked, by no means am I trying to say that. Rather I’m trying to say that me trying to grasp how it worked and trying to use it sucked. So in the end I suck.

I attempted to go to Ogre3D’s website to try and do some tutorials but I didn’t even manage to setup a project to try and do a tutorial. I even installed CMake and tried to get it to install I don’t even know what. I just browsed the website and stared at the triangle logo.

I spent a fair amount of time just staring at this tri-colored triangle.


Overall, I think my main problem is I just don’t know where to start. Trying to find a starting point in a large project and just diving in is, as I find anyways, difficult! I guess I’ll keep trying and try to get some insight/advice from my peers but I have to start cracking down on learning how to use it all. After all, the homework questions need to be done for this class and the cut off dates for the easy questions are coming up along with the midterm! Yikes.


I will be posting as I learn more, what I learn and my personal progress. Hopefully learning TwoLoc/Ogre3D starts to pick up.



On another note I need to get my team together and start committing some code for our GDW project!