Questions tagged [wavefront]

OBJ (or .OBJ) is a geometry definition file format first developed by Wavefront Technologies for its Advanced Visualizer animation package.

334 questions
1
vote
1 answer

Texture mapping on voxel model in Open GL

I'm following a video series about Open GL on YouTube using LWJGL, so far I've managed to render 3d models and texture them properly using the obj format. I want to use voxel-based models for my game so I went in the software MagicaVoxel, exported a…
Thibault Abry
  • 156
  • 10
1
vote
1 answer

OBJ file in surface3d

I have new problem couldnt find any solution in Google ... im using a qml file and it contain a surface3d , when i show it with a obj file that was in qt examples (oilrig) it could show correct without any problems! but when i used my own obj file…
H.M
  • 425
  • 2
  • 16
1
vote
1 answer

Three.js OBJLoader parse method not working

I would like to render my user generated obj instead of loading from file. In my example below, objString represents a cube. The browser just show a dark screen. I'm expecting the display of a green cube rotating. I wonder what I'm missing import…
Daniel
  • 35
  • 6
1
vote
2 answers

How can I improve my file writing method to reduce Wavefront Object file size?

I am trying to write out the voxelization of a model to a Wavefront Object File. My method is simple, and runs in reasonable time. The problem is - it produces OBJ files that are ludicrous in size. I tried to load a 1 GB file into 3D Viewer on a…
Tyler Shellberg
  • 1,086
  • 11
  • 28
1
vote
1 answer

How can I load and render an OBJ file that may include Triangles, Quads, or N-Gons in OpenGL?

I have the following c++ code to load an object file, at least the vertices and the vertex indices. bool ObjMeshImporter::from_file(const std::string& filepath, nelems::Mesh* pMesh) { std::ifstream in(filepath, std::ios::in); if (!in) …
Jayanam
  • 138
  • 1
  • 7
1
vote
0 answers

What's the correct way of obtaining face's normal vectors from OBJ files?

In my path tracer I'm loading OBJ files line by line and I'm loading vertices and vert normals like this: faceVerts = append(faceVerts, [3]Tuple{ vertices[v1-1], vertices[v2-1], vertices[v3-1], }) faceNormals = append(faceNormals, [3]Tuple{ …
hamster121
  • 378
  • 1
  • 4
  • 13
1
vote
1 answer

Lua (trAInsported): trying to implement Wavefront Algorithm, not working

I'm trying to implement a wavefront algorithm and I have a problem with the function, that produces the map with specific gradients. I've tried several different versions of the code below and none of them worked. The starting point for the…
Cpt. Crazy
  • 115
  • 1
  • 11
1
vote
1 answer

How can I replace the C-style string parsing with C++ core guideline-compliant code?

Take for example these two code fragments: //... file_string = strstr(file_string, "\nv "); while (file_string = strstr(file_string, "v ")) { vec::vec3 buffer = { 0.0f }; file_string += strlen("v "); file_string =…
Big Temp
  • 434
  • 4
  • 12
1
vote
0 answers

How to assemble wavefront .obj data into element and vertex arrays of minimal size?

I'm having trouble putting the data inside a wavefront .obj file together. These are the vec3 and vec2 definitions template struct vec3 { T x; T y; T z; }; template struct vec2 { T x; T y; }; Used…
Big Temp
  • 434
  • 4
  • 12
1
vote
1 answer

What does the normals (vn) in wavefront.obj files represent?

I have a 3D mesh in an obj file that was the output of a 3D face-reconstruction algorithm. Problem is that the algorithm mirrors the face along the 2nd axis, i.e. every vertex v x y z is in "reality" v -x y z. I tried the obvious thing to invert all…
Fakher Mokadem
  • 1,059
  • 1
  • 8
  • 22
1
vote
1 answer

Is there a specification available for the Autodesk SVF format?

I'm building a cross platform 3D viewing application in C#/C++ and would like to add support for Autodesk SVF files. I looked at Autodesk Forge but it has limited support for exporting to open formats such as OBJ, and Autodesk SVF does not appear…
anderslu
  • 126
  • 9
1
vote
1 answer

Understanding code drawing .obj in modern OpenGL and setting different positions

I'm watching modern OpenGL tutorial and I don't fully understand code that draws .obj file. I mean it works pretty nice but I've got a little problem with changing position of displayed object. Vertex arrays are generated by glGenVertexArrays() and…
user9717641
1
vote
0 answers

Rendering multiple OBJ models with individual object transformation?

I want to render more than one mesh with each one having its own transformation. Using this tutorial to begin with I have modified few things like added a new model: Model anotherModel( "path_to_obj_file" ); and after the "ourModel.Draw( shader )"…
1
vote
1 answer

What is best way to use wavefront material file color parameter Kd to set vertex color in MetalKit submeshes?

I am developing a MacOS program using MacOS MetalKit and ModelIO. The ultimate goal is to use the 3D model to analyze the acoustic properties of a performance space. Initially I'm just creating a visual image of the space (stage, walls, seating,…
1
vote
1 answer

Calculating normals for model lighting results in the model no longer rendering

I'm working on a simple render engine in java which can render OBJ files to the screen. I'm currently working on the lighting system which is used to light up the models which are present on the screen. Before introducing the lighting system I was…
BRHSM
  • 854
  • 3
  • 13
  • 48