Write an OpenGL program to read and display a 3D mesh .obj file
$10-30 USD
Закрито
Опублікований about 6 years ago
$10-30 USD
Оплачується при отриманні
Write an OpenGL program to read and display a 3D mesh (in .obj format).
There is a skeleton code to be used, and these are the parameters.
1. Implement the “bool ReadOBJFile(const char filename[])”
function, to read in an obj file and store the elements.
2. Implement the “ComputeBoundingBox()” function, to compute the
bounding box, its diagonal axis length, and its center, then put the camera
at:
x_cam = x_BCenter;
y_cam = y_BCenter;
z_cam = z_BCenter + 1.5 *BoundingBoxDiagonalAxisLength;
and look towards the bounding box center.
3. Implement the “Render_Mesh()” function to finish the OpenGL rendering.
4. Finish the rotation (mouse left button), panning (mouse middle button),
and zooming (mouse right button) functions.