Commit graph

135 commits

Author SHA1 Message Date
ZappoMan
a53f84fcb9 latest hacking 2013-05-20 15:51:47 -07:00
ZappoMan
321d1952d6 first cut at exists bits 2013-05-20 12:56:59 -07:00
Andrzej Kapolka
0f2f4ee8f9 Add the discussed four lines to disable blending and enable backface culling. 2013-05-20 11:32:32 -07:00
Stephen Birarda
fc0448a148 disallow copying of VoxelSystem objects 2013-05-17 12:32:42 -07:00
Andrzej Kapolka
86ddcea87f Better names for the shaders. 2013-05-16 13:08:21 -07:00
Andrzej Kapolka
0a6b4702c6 Experimenting with simple Perlin noise shader for voxels. 2013-05-15 22:18:56 -07:00
ZappoMan
8dc61d89fc Added support for "destructive" vs "non-destructive" voxel create
- changed VoxelTree to support destructive and non-destructive mode
- added protocol packet headers to differentiate
- added new UI to switch modes
- default mode now, non-destructive.
2013-05-14 14:19:31 -07:00
ZappoMan
b196227385 Added wantResIn and wantColor feature between client and server
- Updated Voxel Server to support non-res-in version of voxel distribution
- Updated agent data to allow client to send desired res-in and color state
- added menu items to client debug menu to toggle wantResIn and wantColor
2013-05-13 15:02:46 -07:00
Andrzej Kapolka
7a653741de Don't set the renderFullVBOs flag; that's not the problem. 2013-05-13 12:30:56 -07:00
Andrzej Kapolka
eb77f5ff83 Removed debug code, more tests for staged-for-deletion. 2013-05-12 20:36:10 -07:00
Andrzej Kapolka
be88fec7d3 Fixed the major bug, which is that non-leaves were being collapsed. Update
full VBO on deletion, since otherwise we don't see the update.
2013-05-12 20:08:01 -07:00
Andrzej Kapolka
9802403749 Let's do some locking to prevent simultaneous access from different threads. 2013-05-11 15:38:49 -07:00
Andrzej Kapolka
750843e867 More editing progress. Now there are threading issues. Joy! 2013-05-10 21:02:08 -07:00
ZappoMan
ddd55104c1 CR feedback 2013-05-10 14:45:18 -07:00
ZappoMan
ef20b3e4b3 optimized performance of VoxelNode::isLeaf() 2013-05-10 14:32:44 -07:00
ZappoMan
322cb2ff23 implemented partial VBOs support in copyWrittenDataToReadArrays() 2013-05-10 13:18:51 -07:00
ZappoMan
3af8a1b8f4 code review fixes 2013-05-10 10:03:28 -07:00
ZappoMan
9dc09de75e make VoxelSystem::deleteVoxelAt() work properly 2013-05-10 09:32:56 -07:00
ZappoMan
4fe93af5cd create and delete voxels locally 2013-05-09 22:22:32 -07:00
ZappoMan
bd3ea6ef65 create and delete voxels locally 2013-05-09 22:20:13 -07:00
ZappoMan
2128cb8bff get rid of dead code 2013-05-09 17:10:25 -07:00
ZappoMan
33fc9f5389 fixed partial VBO updates 2013-05-09 17:01:20 -07:00
ZappoMan
3aa862fa34 removed some debug messages 2013-05-09 14:19:42 -07:00
ZappoMan
c73d4ddfa4 Merge branch 'master' of https://github.com/worklist/hifi into render_voxels_optimization 2013-05-09 14:06:42 -07:00
ZappoMan
f490f3ed53 More work on partial VBO updates still not working 100% correctly 2013-05-09 14:04:08 -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
ZappoMan
655f14121d Voxel Render Optimization - using blended VBO update strategy
- Fixed a bug in updateNodeInArraysAsFullVBO() that caused blended strategy
  to not work properly.
- Implement strategy to usually update only the portion of the VBOs that
  have changed, unless nodes have been removed, and then update the full
  VBO. This siginificantly improves treeToArrays() performance
- Still to do implement partial strategy for copy buffers and update GPU
2013-05-09 10:25:12 -07:00
Andrzej Kapolka
0cff127082 Merge branch 'master' of https://github.com/worklist/hifi 2013-05-09 09:56:58 -07:00
Andrzej Kapolka
785e55e06f Working on voxel editing. 2013-05-09 09:56:35 -07:00
ZappoMan
bb65137b7e Optimized performance of newTreeToArrays() by implementing blended VBO strategy
- Introduced concept of sometimes only updating the new/changed part of the VBO
  while other times updating the full VBO. This allows us to get the speed
  advantage of only partial VBO updates when nodes haven't been removed
- Some debugging output related to _alwaysRenderFullVBO
- added cleanupRemovedVoxels() which actually deletes the nodes that were
  previously removed (fixes a memory leak!!)
2013-05-08 20:33:41 -07:00
ZappoMan
244b4a17f7 lowered voxel count so Ryan can run, and handle too many voxels case slightly more gracefully than crashing 2013-05-08 18:06:13 -07:00
ZappoMan
cb5ccee1e4 CR cleanup 2013-05-08 14:32:55 -07:00
ZappoMan
ed30a03b2e CR cleanup 2013-05-08 14:30:18 -07:00
ZappoMan
70557cd51c Optimized removeOutOfView()
- don't recurse down trees that are fully INSIDE of the view frustum, because those nodes
  are guaranteed to also be INSIDE
- changes to extraData of the recurse operation to make this possible
- adding debug stats to track how many nodes are inside, outside, intersect
- change call to removeOutOfView() to not call if last elapsed time has not
  yet passed since last call (similar to treeToArrays() logic)
2013-05-08 14:24:08 -07:00
ZappoMan
7a5ce57b4e added alwaysDisplay mode to PerformanceWarnings class 2013-05-08 12:01:55 -07:00
ZappoMan
f1425216ba removed VoxelSystem::createSphere() which was dead code 2013-05-08 00:45:27 -07:00
ZappoMan
84da976383 removed _voxelCleanupLock 2013-05-06 16:38:24 -07:00
ZappoMan
f5808f43b5 some cleanup pre CR 2013-05-06 16:24:09 -07:00
ZappoMan
94529d54e8 some cleanup pre CR 2013-05-06 16:16:21 -07:00
ZappoMan
b69c1a3474 some cleanup pre CR 2013-05-06 16:14:10 -07:00
ZappoMan
68d58650a5 removed some debug code 2013-05-06 16:09:21 -07:00
ZappoMan
09923d1c97 second cut at view culling voxels 2013-05-06 15:51:56 -07:00
ZappoMan
7ba9d4aa86 First cut are removing out of view voxels and switch to using PerformanceWarnings 2013-05-06 13:32:09 -07:00
ZappoMan
af6f51527a short circuit shouldRender logic in treeToArrays() 2013-05-05 10:34:09 -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
ZappoMan
a4f2dc283d various changes to help debug render pipeline
- fixing some cases where TREE_SCALE was not using constant in prep for making TREE_SCALE larger
- added createLine() to VoxelTree
- added axis lines made of voxels to scene
- added corner points made of voxels to scene
2013-05-03 09:58:52 -07:00
ZappoMan
34a059db9a more optimizations of render pipeline 2013-05-02 22:26:56 -07:00
ZappoMan
771c604121 more render pipeline optimizations 2013-05-02 18:12:55 -07:00
ZappoMan
fcce4753c9 more optimizations on render pipeline 2013-05-02 16:37:31 -07:00
ZappoMan
5a14c71225 added dirty bit support to VoxelTree, use it to determine when to call treeToArrays 2013-05-02 15:57:31 -07:00