Questions tagged [octree]

An octree is a tree data structure in which each node has eight child nodes. A major application of octrees is in 3d graphics as they are the primary structure used for storing voxel (volumetric pixel) data.

Wikipedia: "An octree is a tree data structure in which each internal node has exactly eight children. Octrees are most often used to partition a three dimensional space by recursively subdividing it into eight octants. Octrees are the three-dimensional analog of quadtrees."

Relevant topics include voxels and color quantization.
For more information see http://en.wikipedia.org/wiki/Octree

148 questions
0
votes
1 answer

Occlusion culling for spinning sphere dataset

I am currently working on an assignment in which I have to implement a CPU-only rasterizer for sphere datasets. The datasets are static and therefore don´t change in runtime, even though the whole set can rotate in front of the camera. The idea now…
0
votes
1 answer

Impose voxel grid on 3D point cloud

I am working with structured 2.5D and unstructured 3D data, which generally is available in (X,Y,Z) coordinates, i.e. point clouds. Now I want to impose a regular voxel grid onto the data. This is not meant for visualization purposes, but rather for…
Michael
  • 280
  • 2
  • 13
0
votes
1 answer

Java - 3D Arrays trim method acting up

I created this method to trim 3D arrays to use in Octrees. For some weird reason that I cant figure out after returning the trimmed array its just full of zeros. When it should be filled with ones. Here is the code to better explain: int[][][]…
Amit Assaraf
  • 512
  • 11
  • 34
0
votes
1 answer

Where can I find a tutorial/example or help on "Octree" with XNA?

I am developing a small minecraft style game on XNA. I generates a voxel mode, so I'm looking to be optimized to the maximum my matrix "World"! This is the one I'm looking for example "How to Use Octree with Xna ?." Unfortunately, I have not found a…
Mehdi Bugnard
  • 3,889
  • 4
  • 45
  • 86
0
votes
4 answers

Invoking delete on an octree array

So I wrote an octree struct, as follows: struct octree{ static const int maxdepth=8; octree* child[8]; uint32_t rgb;//candidates for the extra 8 bits: alpha, lighting, shape(to reduce size) uint8_t shape; ~octree(){delete[]…
0
votes
1 answer

Store Vertices DirectX C++

Im currently implementing an Octree for my bachelor thesis project. My Octree takes a std::vector as argument: octree::Octree::Octree(std::vector vec) : m_vertices(std::vector()), …
Chris
  • 1,226
  • 1
  • 12
  • 26
-1
votes
2 answers

Octant partition equally a cloud of points in 3D

Is there a better way to do this? Not necessarily prettier, although it would be nice. P = [N,3] ‘Cloud of points’ P -= np.sum(P, axis=0) / P.shape[0] Map = [i for i in range(P.shape[0])] p_0 = Map[P[:,0] <= 0] p_1 = Map[P[:,0] > 0] p_0_0 =…
-1
votes
2 answers

C++ Using sizeof() to determine size of an Octree

Let's say Octree() is a container with Elements of type double. Can I use sizeof(Octree) to determine how much memory in bytes is taken up by my octree? Sizeof() should change if I change the resolution/depth of my octree - which does not seem to be…
copcor
  • 55
  • 6
-1
votes
1 answer

How to return a pointer to the parent node of children[poz] in the following code?

I am trying to find a specific RGB point in an octree ( after I have inserted it already) and I want this function to return a pointer to that node's parent or a list with the node and its brothers. How can I change this code to get that? Also when…
gverenti
  • 7
  • 3
-1
votes
1 answer

Problem with triangle-triangle collision detection

I'm developing a game engine for a university project and I can't get the collision detection system to work. I've found this paper that explains an algorithm for triangle-triangle collision detection created by Chaman-Leopoldj, but somehow I can't…
theguga96
  • 1
  • 1
-1
votes
1 answer

Threading an octree

Efficient way of threading an octree such that the pointers contained by each octcell in an oct make it easy in the traversal through the tree at the same level. We have to make use of fully threaded trees here so that i can use openmp to…
Aakash Anuj
  • 3,773
  • 7
  • 35
  • 47
-2
votes
2 answers

Suggest a book on spatial data structures

Please advice a book on spatial data structures. I'm interested in Quadtrees and Octrees.
shaikh
  • 1,355
  • 4
  • 16
  • 30
-2
votes
1 answer

How do I find the amount of levels in an Octree if I have N nodes?

If the octree level is 0, then I have 8 nodes. Now, if the octree level is 1, then I have 72 nodes. But if I have (for example) 500 nodes, how do I calculate what the level would be?
Merry
  • 3
  • 2
1 2 3
9
10