[MDX] [C#] Ray Picking and Point list brightness issues
Posted on 2006-05-08
Rather than ask 2 questions, I'll stick them both in here.
Problem #1 (for 250 points):
I have a space station, I have a camera. I am trying to pick the distance of the station from the camera and the space station face being looked at, mostly for docking purposes. This was working brilliantly (detected distance perfectly and showed the right face number). However, when I decided to move the space station 1000 units in an arbitary direction, the total distance became the camera distance to the space station + the distance from the space station to the origin. Now this could probably be solved with pythagoras, but I'd rather find the problem in my code if there is one.
Problem #2 (for 125 point bonus):
I have a skybox, a pointlist, and my camera. Lighting is disabled. I have coded the pointlist to flicker in intensity (higher values of grey to white). The skybox and the pointlist are rendered whilst the z-buffer is disabled, and the skybox is rendered BEFORE the pointlist. The problem is that when the skybox is enabled the pointlist is all black, I can tell this because I can see a few of the points in the bright patches of my skybox texture. I tested rendering only 1 subset of my skybox and the points all appear blue, and flicker in intensity. When the skybox is disabled the points all appear perfect and flickering grey-white. I need to find out why my skybox is influencing my pointlist.
Does anyone have any ideas? If people provide really good answers, I'll consider dumping more points on this question.