Hello,
I would like to model mouldings for picture frame in 3d, and got pretty excited about the ExtrudeGeometry feature.
Using it would allow me to simply model the profile once and create the 3d moulding by extruding the profile.
Here are what profiles could look like:
Make 4 of those meshes, size and position them in an Object3d, then texture them probably using DecalGeometry.
The tricky thing is that the intersecting corners should reflect the actual intersection like so:
Seems to me like I have no choice but to slice each ends of meshes at a 45 degree angle to obtain the best result.
What is the best way to achieve that?
Thanks to @prisoner849’s ProfiledContourGeometry I have been able to achieve the desired effect.
Many thanks for that code.
Now I have been looking at how to apply a texture to the front facing faces of the frame and boy does it look complicated.
I basically would have to control where the mapping begins, where it ends, follow the planes in between, scale it to the right dimensions and eventually repeat it (programatically).
Any good resources to learn how to do that?
Would a DecalGeometry be easier in this case?
recording (1).mkv (915.8 KB)
This is the image, i want to achieve trying to create a dynamic drawing tool where users click to define a shape, and then the shape is extruded along the drawn lines to form a window-like structure.
Click to Define Shape: Users click to define the shape of a window frame.Auto-Complete Shape: Once the user completes the shape by clicking near the starting point, the shape should close.Extrude Along Drawn Lines: The shape should be extruded along the clicked path to create a 3D window frame.Ensure Proper Angles and Transformations: The frame edges should have correct angles for a realistic window frame.