react-three-renderer icon indicating copy to clipboard operation
react-three-renderer copied to clipboard

Translating OpenGL objects to React-three-renderer

Open p-fernandez opened this issue 8 years ago • 2 comments

I am trying to import OpenGL 3D models into React Three Renderer to make a simple app that is able to do slight modifications on said models.

A typical OpenGL structure XML file for mesh would be like this:

<surfaces>
    <quad>
        <mesh width="1" height="1">-1,-1,0.125,0,1,-1,0.875,0,-1,1,0.125,1,1,1,0.875,1</mesh>
    </quad>
    <quad>
        <mesh width="1" height="1">-1,-1,-3.72529e-09,0,1,-1,1,0,-1,1,-3.72529e-09,1,1,1,1,1</mesh>
    </quad>
    <quad>
        <mesh width="1" height="1">-1,-1,-3.72529e-09,0,1,-1,1,0,-1,1,-3.72529e-09,1,1,1,1,1</mesh>
    </quad>
</surfaces>

Is there any react-three-renderer component that can be instantiated from a 4x4 matrix like the one provided by the OpenGL mesh? Or should I need to create manually all the vertices from said matrix? Thank you!

p-fernandez avatar Apr 04 '17 10:04 p-fernandez

Can you please provide a link to the XML spec? Currently I am not sure if such a loader exists.

#57 seems to be related as well.

I'll continue adding notes when I get an opportunity to look deeper :)

toxicFork avatar Apr 15 '17 14:04 toxicFork

As far as I know it is version 0.4, but I am unable to find a specification document. I might be able to ask for it to the software developers that generate those xml files of the OpenGL models.

Thank you for the linked issue, though I don't find it completely helpful for my goal.

p-fernandez avatar Apr 25 '17 16:04 p-fernandez