I need some tips both visually and in detailed explained. When designing a game engine of some sort. (and I am considering that it is difficult to implement one) How do engines allow you to create different kinds of geometry such as a line, cube, rectangle, triangle, and spheres without telling the vertices of these basic geometry? What are different methodologies to approach this sort of thing?For some more context the idea that I was hoping would be you would have some function like the following below. Where you wanted to draw those specific geometry, and what are different approaches to instantiate these different kinds of geometry when developing an engine to automate this process?BeginScene();DrawCube(pos, size, color); DrawSphere(pos, size, color); EndScene();
I need some tips both visually and in detailed explained. When designing a game engine of some sort. (and I am considering that it is difficult to implement one) How do engines allow you to create different kinds of geometry such as a line, cube, rectangle, triangle, and spheres without telling the vertices of these basic geometry? What are different methodologies to approach this sort of thing?
For some more context the idea that I was hoping would be you would have some function like the following below. Where you wanted to draw those specific geometry, and what are different approaches to instantiate these different kinds of geometry when developing an engine to automate this process?
BeginScene();
DrawCube(pos, size, color);
DrawSphere(pos, size, color);
EndScene();
Step by step
Solved in 2 steps with 2 images