문제

How can I draw shapes other than cubes with x3dom? For instance, one shape I want to draw is a semi circle/cylinder. I can only find documentation to draw a cube which I already do. I have not found good documentation yet for x3dom.

도움이 되었습니까?

해결책

X3DOM actually just wraps X3D. So you may better start with the X3D documentation. A quite good overview can be found here: X3D Slides.

There are some other primitives provided like:

<Shape>
  <Sphere radius='1'/>
  <Appearance>
    <Material/>
  </Appearance>
</Shape>

Also the examples provide a good starting point.

다른 팁

to use a cylinder just use this in the shape node

<Cylinder />

as mistapink says check out the x3d docs, there are a few basic x3d primitives, such as sphere box cylinder cone.

anything more elaborate would require you to use pointsets etc. or you can model your own objects and export to x3d through lots of 3d apps, blender , 3d max , lightwave etc

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top