Goal:
The goal is to create a Babylon.js application that allows the user to draw arbitrary 2D shapes on the ground plane, extrude them into 3D objects with a fixed height, and then manipulate those objects by moving the object and editing their vertices using buttons for mode selection.
Features:
- A 3D scene with a ground plane.
- Functionality to allow the user to draw 2D shapes on the ground plane using mouse interactions
- left-click to add points
- right-click to complete the shape
- Draw button to enter the draw mode - Extrude button to initiate the extrusion of 2D Closed loop polygons to a height of 5 units.
- Move button to perform movement of extruded shapes on the ground plane
- Edit button to edit the vertices of the extruded object using mouse interactions.
- Visual cues and UI elements to indicate the selected object and active editing mode.
How To run the application:
- Clone the repository to your local
- Run the HTML file to view it on your web browser
A glimpse into the Application:
- 3D scene with Ground plane
![](https://private-user-images.githubusercontent.com/72205755/285543158-14fb2135-6503-46c2-b1cd-1b67ca2e3b13.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MzkyNzY4NTUsIm5iZiI6MTczOTI3NjU1NSwicGF0aCI6Ii83MjIwNTc1NS8yODU1NDMxNTgtMTRmYjIxMzUtNjUwMy00NmMyLWIxY2QtMWI2N2NhMmUzYjEzLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNTAyMTElMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjUwMjExVDEyMjIzNVomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPWI5YzM2OTQ1YTA2MjU3MWU0ZDlmNWU5ODUwNWJhNjZkMmZiYmVlZjA0MjU5Y2YyZjEzYzBlOWMxMjAwMzFlZmImWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0In0.oY6JOoznsy_CGXl6UsxLeTtY9bOoRmeUuj8sOcvyzC0)
- Draw 2D shapes on the ground with mose interactions
- Extrusion of 2D shapes to 3D
- Movement of extruded polygons with visual cues
- Edit Vertices