magic-script-components icon indicating copy to clipboard operation
magic-script-components copied to clipboard

Custom Shapes

Open pleszkiewicz opened this issue 6 years ago • 0 comments

Description

This could be a Shape tag where we have a list of predefined 2D and 3D shapes created by LineNodes. We might even be able to implement it in Pure JavaScript. Shape tag with preset shapes and if developers want more then we allow them to provide meshes or use three.js needs coordination with LRE.

<Shape 
  vertices={[[0,0,0], [0,1,0], [1,0,0]} 
  indices={[0,1,2]} 
  texCoords={...} 
  texture={...} 
/>

<Shape 
  primitive={'cone'} 
  radius={0.5} 
  height={0.8} 
/>

<Shape 
  primitive={'torus'} 
  innerRadius={0.5} 
  outerRadius={1} 
/>

Completion status

  • [ ] Android
  • [ ] iOS
  • [ ] Lumin

pleszkiewicz avatar Jan 20 '20 09:01 pleszkiewicz