Skip to content

Latest commit

 

History

History

orx-obj-loader

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 

orx-obj-loader

Simple loader and saver for Wavefront .obj 3D mesh files.

Usage

Loading directly into a vertex buffer can be done through loadOBJasVertexBuffer.

val vertexBuffer = loadOBJasVertexBuffer("data/someObject.obj")

The loaded vertex buffer can be drawn like this:

drawer.vertexBuffer(vertexBuffer, DrawPrimitive.TRIANGLES)

To save a vertex buffer as an .obj file:

vertexBuffer.saveOBJ("my/path/exported.obj")

Demos

DemoObjCompoundRW01

source code

DemoObjCompoundRW01Kt

DemoObjLoader01

source code

DemoObjLoader01Kt

DemoObjSaver01

source code

DemoObjSaver01Kt

DemoObjSaver02

source code

DemoObjSaver02Kt

DemoWireframe01

source code

DemoWireframe01Kt