02/27/05

Ok... I added something pretty cool to the site! Try to guess what it is!

Awwww... come on. You’re not even trying! Ok... forget it!

If you look over at the buttons on the left you’ll notice that I finally added some forums to the site. That’s right... you no longer have to leave this site to ask your questions or to get your daily dose of people arguing over crucial issues such as OpenGL vs. Direct3D or more importantly… Ninjas vs. Vampires.

So, run along and get registered before all the good names are taken and you get stuck with, _Mr_Fluffy_, or village_idiot079.

Why are you still here?! Go now!

02/17/05

Added a new spot light sample to the DirectX 9.0 page to match the point light sample.

02/15/05

Two new samples have been uploaded. The first one is a Linux port of the OpenGL based pixel buffer sample, and the second one is a simple point lighting sample for DirectX 9.0, which I feel is more suitable for beginners than my first Direct3D lighting sample, which gets a little complicated since it demos all three light types in one sample.

Off-screen Rendering Using Pixel Buffers (OpenGL - Linux)
Point Lighting (DirectX 9.0)

Please note that the original pixel buffer sample (OpenGL - Win32) was split into three versions depending the method used to create the dynamic texture and, so far, only version #2 has been ported to Linux. Version #1 is simple enough, but I'm still researching how version #3 can be ported to Linux since it uses the Windows only extension WGL_ARB_render_texture. Unfortunately, none of my cards seem to support the GLX_ARB_render_texture extension so I'm now forced to look at the vendor specific extensions.

02/09/05

Alright... I’m getting tired of looking at OpenGL code! My brain is starting to function like a GL state machine:

// Prepare to watch a little TV!
glDisable( GL_LIGHT0 );
glMatrixMode( GL_MODELVIEW );
glLoadIdentity();

gluLookAt( 5.0, 0.0, 5.0,   // Couch position
           0.0, 1.5, 0.0,   // TV position
           0.0, 1.0, 0.0 ); // Up vector


It’s definitely time for some new Direct3D samples:

Simple Vertex & Pixel Shader using HLSL
Simple Introduction to the NovodeX Physics SDK

02/08/05

Lucky you! Some research at work has spawned yet another new OpenGL sample... if you can call it work. Can you believe I get paid to research and program 3D graphics! Those suckers! I'd do it for FREE if I had to! Of course, that's between you and me... tell no one. I'm currently bucking for a pay raise so I can buy hundreds of SLI enhanced nVIDIA cards, chain them together into a massive parallel pixel pumping machine and take over the world!

Buwhahahaha ha ha, Buwhahahaha ha!

Ok... it's official. I've been up way too long with out sleep!

Any way, this new sample deals with a multitexture blending technique which is very useful for blending terrain textures together. Actually, it's a fairly old technique, which is quickly being replaced by shaders, but its nice to know it if you need a fall-back for older cards.

02/07/05

I finally decided to stop being lazy and port the popular Cg skinning sample to GLslang. Well, it's not really laziness. I was just putting it off a bit till I had time to read the new OpenGL Shading Language book. It really does clear a few things up and I highly recommend it to anyone who is seriously into shader development. It's definitely better than reading a million misleading forum threads, which was really starting to give me a headache!

02/03/05

Three new OpenGL samples have been posted:

Color Tracking and Two-Sided Lighting
Multi-Texturing with Cg
Simple Introduction to the NovodeX Physics SDK

The first two resulted from helping some people out with a few questions and third one is the first one in a new series on game physics. I initially started this series off using the Tokamak SDK, but its development has basically slowed to a crawl and I’m afraid it’s not making much headway. The Novodex SDK is very similar to Tokamak and it was recently selected by Epic Games for their Unreal engine so you know they got their stuff together. On top of that, you can download and use Novodex SDK for free for non-commercial applications. Of course, I’ll leave the Tokamak samples up as long people want them. Tokamak's last release (1.2) is very stable and their license is a little more liberal.

02/01/05

If you visit this site for OpenGL code you should know that there’s been a major overhaul of the OpenGL samples. I’ve decided to clean up my samples by removing any dependencies on GLUT that may exist. Don’t get me wrong, GLUT is a fine windowing toolkit but most of my OpenGL samples already use the Win32 API to create their window so I don’t really need GLUT for that. All I really use from GLUT is the teapot model and the functions related to bitmap based character fonts and it seems a shame to have to link in a whole library just for that. So… to sever this tie I download the source code to Freeglut and I pulled out everything that I would need to become literally free from GLUT.

The great thing about this change is that it eliminates a whole category of, "Help! Your code doesn’t compile!" emails. Now, newbie programmers who don’t have GLUT installed, let alone now what it is, can just download the samples and compile away. Of course, you still need a compiler, which results in another category of emails that I call, "I changed your code with Notepad, but nothing happens!" emails. Yikes! ;)

Also, all of the Cg shader samples have been updated to Cg 1.3 so if Cg is your thing, check them out. They’ll probably get updated a few more times while I attempt to replace all of the deprecated features with the new features.

You should also note that a few of the OpenGL based samples that use Cg still refuse to work on my ATI card (Radeon 9700 Pro) but somehow "mysteriously" work fine on my nVIDIA card (GeForce 5900 FX Ultra). I’m working on it, but it’s most likely a bug in Cg 1.3 since the samples in question are so simple and worked fine under Cg 1.2.1. Either way, it's annoying since Cg was supposed to be agnostic when it comes to the hardware and this feature of the language seems to be slipping away with each release.

01/18/05

If you’re interested, all of the GLslang shader samples have been updated. They now make better use GLslang's built-in variables when needed. This allows me to fix the problem I had earlier where I was being forced to create both a vertex and fragment shader when I only needed one or the other - but not both.

01/17/05

I have another shader port for you guys. This time I have ported the grayscale shader from Cg to GLslang. Hopefully, these side-by-side comparisons of different shader APIs prove useful for those of you out there who are trying to navigate the seemingly endless sea of shader options.

I also fixed a few of the OpenGL samples which use a textured sphere for testing purposes. The code that generated the sphere was accidentally laying the texture coordinates out in reverse which was causing the textures to be applied backwards. Several months ago someone out there emailed me about this problem, but I lost the email and totally forgot about it till someone at work mentioned it again. Sorry about that.

I’m actually surprised that in two something years only two people noticed that the earth texture used in those samples was being applied backwards! Come on people... it's our home planet! You guys should notice things like that... unless, of course, this is not your home planet and based on a few of the weird emails that I get... there's a few of you out there! That's why I recently added a few sample that use a texture map of Mars instead. You know... I'm just trying to make you guys feel at home. ;)

01/12/05

For those of you out there that are currently developing shaders using Cg, you should note that the Cg based shader samples offered on this site require Cg 1.2.1. I haven’t ported any of my samples to the beta release of Cg 1.3 and I probably won't until it officially releases. I just thought that I would warn you now because all of my Cg samples are broken under Cg 1.3 beta 2 and this is confusing some people out there who have that beta installed.

If any one knows a quick fix for this, please let me know. I currently don't have time to investigate it and feel sorry for those that have decided to bite-the-bullet and install this new beta.

01/05/05

For those of you that are interested in learning more about the Torque Game Engine, the Torque tutorials offered by my site have been updated and now use the “tutorial.base” example which ships with Torque. When I first wrote these tutorials, an official starting place for writing Torque tutorials didn’t exist so I was forced to write my own. With time, the Torque team was nice enough to add an official one to their engine's SDK so I decided to port my beginner-level tutorials over to their new “tutorial.base” example. Hopefully, I’ll also find some free-time to write up a few new tutorials as well.

More Site News...