Commit graph

24 commits

Author SHA1 Message Date
ZappoMan
9faef65ccc first cut at splitting out octree base classes 2013-12-03 17:32:02 -08:00
ZappoMan
9ba39c3a84 removed center from AABox to further save memory 2013-10-15 12:05:54 -07:00
ZappoMan
c9b0edf345 first cut at reducing memory footprint of AABox 2013-10-15 11:29:04 -07:00
ZappoMan
64681fa1e4 CR feedback 2013-07-15 09:21:47 -07:00
ZappoMan
f415f4081a Fixed a bug in LOD boundaries
- changed the way we calculate whether or not to render a parent "average" voxel so
  that if any of it's most distant child would not be visible, then it's used instead
  of it's children
- added precalculated value for topFarLeft corner of AABox (optimization)
- changed VoxelSystem::newTreeToArrays() and VoxelTree::encodeTreeBitstreamRecursion()
  to use the same help function for determining this LOD boundary behavior
- deleted old dead code in voxel-server and VoxelTree for picking which node to start
  sending with, since it wasn't being used
- added VoxelNode::furthestDistanceToCamera() which tells you not the distance to the
  center of the voxel, but the distance from the camera to the furthest corner relative
  to the camera.
- added ViewFrustum::getFurthestPointFromCamera() which given an axis-aligned box will
  tell you which vertex of the box is furthest from the camera
2013-07-15 01:32:14 -07:00
ZappoMan
1284f9d09a naming cleanup and some optimizations 2013-06-19 13:45:13 -07:00
ZappoMan
6d8826de43 cleaned up line spacing and tabs, added getVertex() 2013-06-11 12:30:52 -07:00
ZappoMan
a9c18c2af0 cleaned up line spacing and tabs, added getVertex() 2013-06-11 12:28:09 -07:00
Andrzej Kapolka
a6daa296ff Slight fix to capsule/box penetration test: we should use the smaller distance
to the diagonal, not the first one we find.
2013-06-03 10:08:42 -07:00
Andrzej Kapolka
949befee09 Fix for NaN. 2013-05-27 14:37:07 -07:00
Andrzej Kapolka
cfb66bee95 Capsule/box collisions. 2013-05-27 14:05:44 -07:00
Andrzej Kapolka
70b25fd6c4 Sphere/box collisions for voxels, various utility functions. 2013-05-25 19:59:07 -07:00
Andrzej Kapolka
7ff8b84f4c Return the box face, as well as the distance, from the ray intersection test.
Use it to determine which voxel neighbor we create when adding.
2013-05-09 10:46:52 -07:00
Philip Rosedale
69cac10cee null change 2013-05-06 18:21:33 -07:00
ZappoMan
342e3e0407 fixed CR issue 2013-05-06 16:43:25 -07:00
ZappoMan
dc481002ec fixed Xcode compiler warnings 2013-05-06 16:00:43 -07:00
ZappoMan
043a284d4d Merge branch 'master' of https://github.com/worklist/hifi into render_voxels_optimization 2013-05-06 13:36:31 -07:00
ZappoMan
2c8c6a2600 Coding standard cleanup and VoxelNode optimization
- make octalCode and children members private
- add public getters for accessing these private members
- change constructor to require an OctalCode for all non-roots
- default constructor constructs a rootNode
- make primary access for deleting, adding, and accessing children through public methods that do bookkeeping
- calculate AABox on voxel creation so that we don't need to do all the math when we deal with voxels
- added methods on VoxelNode for common items like getCorner(), getCenter(), getLevel(), etc
2013-05-05 10:17:02 -07:00
Andrzej Kapolka
34565a4956 Pointers to references for in/out parameters, renamed line parameter to more
descriptive "distance."
2013-05-04 07:56:30 -07:00
Andrzej Kapolka
ff4e21e504 Remaining pick bits. 2013-05-03 20:12:46 -07:00
Andrzej Kapolka
f8cbe34e07 Added basic ray intersection testing to VoxelTree. 2013-05-03 17:27:57 -07:00
ZappoMan
358efb472d Clean up AABox to coding standard, made several methods const
- Cleaned up AABox to be consistent with the coding standard
- converted some methods to const and fixed up callers
2013-04-21 22:46:13 -07:00
ZappoMan
3ec920d1b8 added scale() method to AABox 2013-04-19 18:14:10 -07:00
ZappoMan
dcca1699d3 Adding first cut at ViewFrustum pointIn,SphereIn,BoxIn code.
- Added Plane class
- Added AABox class
- Removed some experimental "slightly inside" code from view frustum
2013-04-16 11:29:31 -07:00