I dont understand why constants would have dolphinspace information, and what i would do with these lines of code if i have a second dolphin in a different position.

thanks for any input, i know its vague but im just tryin to understand how to maniuplate multiple objects using shader technology. most books i read on shaders use directX8 and c++ and im having trouble getting the understnad.

Many times, constants are used for more specific information for a given model instance in the world. I've used this to add coloring/tinting to different players, but do it inside the shader -- or to do time-offset specific stuff, but allow models to have their own 'time clock'.

You can call the SetVertexShaderConstant calls every frame, for every object, and it won't tank performance -- you'll hit MANY other bottlenecks before it even hits the radar screen. Just modify your code so that anything 'dolphin specific' is stored in a structure per-dolphin, then SVSC should reference the per-dolphin variable as it does setup (or pass a ptr to the dolphin struct for each setup call, making it more abstracted).

There's a ton of new books on the market dealing with DX9, and with DX9 shaders -- worth checking out amazon/borders/etc. and picking up one or two.

-d

0

Featured Post

Your application or website rely on your database to deliver information about products and services to your customers. You can’t afford to have your database lose performance, lose availability or become unresponsive – even for just a few minutes.

Artificial Intelligence comes in many forms, and for game developers, Path-Finding is an important ability for making an NPC (Non-Playable Character) maneuver through terrain. A* is a particularly easy way to approach it. I’ll start with the algor…

Performance in games development is paramount: every microsecond counts to be able to do everything in less than 33ms (aiming at 16ms). C# foreach statement is one of the worst performance killers, and here I explain why.

In this episode Don builds upon the troubleshooting techniques by demonstrating how to properly monitor a vSphere deployment to detect problems before they occur. He begins the show using tools found within the vSphere suite as ends the show demonst…

Want to learn how to record your desktop screen without having to use an outside camera. Click on this video and learn how to use the cool google extension called "Screencastify"!
Step 1: Open a new google tab
Step 2: Go to the left hand upper corn…