Skip to main content
gamedev.net
🔒 Locked

Direct3D Question

Started by mr_slipgate Apr 12, 2001 at 9:58 AM 0 replies 450+ views
Original Post
mr_slipgate
mr_slipgate
Hello all, I have posted a question similar to this about a week ago, but this is a burden for me to do any further work on my engine. I want to be able to plot coordinates for vertices and whatever using screenspace coordinates while still having "3D" space. In other words i want to plot a coordinate at say... 640x480 and plot a vertex normal there too (for lights). D3D has D3DFVF_XYZRHW or something like that, but those cannot use normals... All im really asking for, is to be able to plot coordinates using my current monitor resolution as the screen coordinates and the ability to use vertex normals (so i can properly light) Cheers
Pactuul
Pactuul
I think I understand your question there... I suspect you want like a hud or something like that. (or possible make a top down view of a world)

What you want to do is create a orthogangal ( spelling?) projection. Directx8 has a function that does this called something like d3dortho() (look it up I guess) here you can specify a "straight on" view that is still 3d but doesn''t give persepective. You pass 4 main parameters to this function lower-left, lower-right, upper-left, upper-right. Or for you this would be something like 0,0,screenwidth,screenheight. you can also rearrange these 4 parameters so that you can set any corner to be your 0,0.

I hope this helps you out.

Pactuul

"The thing I like about friends in my classes is that they can''t access my private members directly."



-Pac "The thing I like about friends in my classes is that they can't access my private members directly." "When listening to some one tell about their problem (whether it's code or not), don't listen to what went right or wrong, but what they assumed....."

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.