Skip to content

Latest commit

 

History

History
50 lines (32 loc) · 1.45 KB

README.md

File metadata and controls

50 lines (32 loc) · 1.45 KB

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