etherealengine icon indicating copy to clipboard operation
etherealengine copied to clipboard

[EPIC] Object geometry primitives in the editor

Open HexaField opened this issue 3 years ago â€ĸ 8 comments

It would be great to be able to throw primitive shapes into the scene in as easily as other objects, and even able to draw objects. Things like cubes, spheres, planes, etc

These should be saved out as GLTFs upon scene save

MVP

Primitives

  • [x] Box
  • [x] Sphere
  • [x] Cone
  • [x] Cylinder
  • [x] Plane
  • [x] Circle
  • [x] Triangle

Other Features

  • [ ] Material painting
  • [ ] CSG (Constructive Solid Geometry https://github.com/samalexander/three-csg-ts)

Advanced Features

  • [ ] Blender style geometry editor
  • [ ] Deeply integrated material creator
  • [ ] Texture Splatting
  • [ ] https://github.com/EtherealEngine/etherealengine/issues/7821

HexaField avatar Aug 12 '22 22:08 HexaField

for the primitives i can just let it be a model component, and add the respective shape/geometry on it in three js when the component is added to the scene

now i have a question do we create separate components for all the shapes , or just a single component, with a dropdown for the shapes?

SYBIOTE avatar Oct 09 '23 19:10 SYBIOTE

we might want to rework the ground plane component into this primitive component

SYBIOTE avatar Oct 09 '23 19:10 SYBIOTE

questions,

how do we handle csg for more than two entites interacting? union and intersect can be done on multiple, what is the expected behavior for difference on multiple entities? for the csg we could follow different UX

  1. for multiple entity interaction , we could follow what godot does
  • the csg component is the parent entity
  • entities with model under it form a group which apply the csg on each other, ordering matter, first child gets priority
  • entities with csg component under it, treat the group as a whole model and so on
  1. csg is constrained to two entities at a time

SYBIOTE avatar Oct 09 '23 19:10 SYBIOTE

we might want to rework the ground plane component into this primitive component

No, ground planes are not solid geometries and have special logic associated.

HexaField avatar Oct 09 '23 20:10 HexaField

for the primitives i can just let it be a model component, and add the respective shape/geometry on it in three js when the component is added to the scene

now i have a question do we create separate components for all the shapes , or just a single component, with a dropdown for the shapes?

It should just be the model component, and we have a special menu to add primitives. No need to add components for each.

HexaField avatar Oct 09 '23 20:10 HexaField

got that, lets start with that

SYBIOTE avatar Oct 10 '23 01:10 SYBIOTE

done with the geometry, its going to be a while before we can focus on the other and advanced features

SYBIOTE avatar Dec 03 '23 21:12 SYBIOTE

I'm ready to integrate csg when needed

SYBIOTE avatar Mar 25 '24 22:03 SYBIOTE