how to use gdi or gdi+ draw a cube and rotate it ?
--------------begin hi----------------
how to use gdi or gdi+ draw a cube and rotate it ? who can help me ?
i hope use 3d math class.
who can give some help .write a simple demo?
--------------e n d hi----------------
only use gdi or gdi+
please help me.thanks very very much.
If you are gonne be satisfied with orthogonal view and wireframe filling then you simply have to calculate rotation matrice and multiply it with the position vectors of your vertices, and ignore the Z value to draw on your canvas :) "3d Transformation matrices" would be a good start for searching.
if anybody give me a simple demo example,it is best.i wanna very very thanks.
i'm a newbie.please give me some help.thanks a lot.
i'm a newbie.please give me some help.thanks a lot.
Hi. I found the following link, which contains C# code using GDC+ to draw a 3D cube. I make no promises that the code is good. No, it is not C++, but hopefully you can adapt it yourself.
Rotating a 3D Cube and Sphere with GDI+
Now...although I've provided a link to someone's example code, I do highly recommend that you go an learn about 3D projection matrices, and the 3D graphics pipeline yourself. If you hope to do any serious 3D programming, you will need to truly understand the underlying math and geometry.
Rotating a 3D Cube and Sphere with GDI+
Now...although I've provided a link to someone's example code, I do highly recommend that you go an learn about 3D projection matrices, and the 3D graphics pipeline yourself. If you hope to do any serious 3D programming, you will need to truly understand the underlying math and geometry.
Having someone hand you a solution is not the best way to learn. Providing you with an "example" that you can directly use in your project without truely understanding it, will do you nothing.
All this would show is that you have the abillity to steal other peoples work.
Learn how to do things yourself, it is the only way that you will learn!
All this would show is that you have the abillity to steal other peoples work.
Learn how to do things yourself, it is the only way that you will learn!
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement