Commit Graph

87 Commits

Author SHA1 Message Date
bdf5c36711 Now VoxelWorldDefault will update lods if a player is set by default. This can be turned off via a new use_default_lod_update property. Also smaller fixes to the default lod update algorithm. 2022-02-09 14:25:32 +01:00
0ab76c86bc Set num_lods in _create_chunk for now, it really needs to be removed though. 2022-02-09 14:10:58 +01:00
a67bc1eeba FastQuadraticMeshSimplifier should have been allocated for the voxel jobs. 2022-02-09 13:57:19 +01:00
9ee54a48c4 Add the new prop job setup to all 4 (3) VoxelWorlds. 2022-02-09 13:34:24 +01:00
a01988fb06 Update initialization of all 3 VoxelWorld implementations to use the new style. (It is not yet enabled.) 2022-02-09 12:45:32 +01:00
8d7289b0b3 Changed the default lod stup for VoxelWorldDefault::_create_chunk, as nothing supports normal lods in this module. (Normal lods would be lods created with the Transvoxel algorithm for example.) 2022-02-09 10:24:49 +01:00
e9269bc0b3 Also update VoxelWorldDefault::_create_chunk. 2022-02-09 00:19:26 +01:00
fe4a83b909 Changed the Voxelman prefix of the classes to just Voxel as suggested by filipworksdev. Closes #5. Thanks. 2022-02-08 12:36:37 +01:00
abe5db00cb Work on fixing compile for 4.0. 2022-02-07 00:15:44 +01:00
547aeaad4d Fix compile for 4.0. 2021-02-06 11:51:50 +01:00
f4ba38ecd0 Same treatment to the mesh related methods in VoxelChunkDefault. 2020-10-27 19:04:20 +01:00
1da900a5e8 Same treatment to the chunk related methods in VoxelWorld. I kept the virtuals the same. 2020-10-27 18:22:18 +01:00
2dec05f80f Also renamed the channel-related methods in VoxelChunk. 2020-10-27 12:45:15 +01:00
1d1fdf5c56 Same treatment to jobs in VoxelChunk. 2020-10-26 18:29:05 +01:00
851b4efb52 Same change to the collider-related method in VoxelChunk. 2020-10-26 17:24:22 +01:00
7311297906 Chunks that are stored inside worlds in scenes will properly generate their meshes now on load. Had to change _create_chunk a bit, now it will be called for all chunks, and it needs to check whether it has to init jobs or not. 2020-10-24 22:18:23 +02:00
6e68267bd0 My mesh utils module is now an optional dependency. The terrarin job will use it to simplify meshes over lod level 4. 2020-10-20 16:29:39 +02:00
0e4e59e970 Remove create_mesher and _create_mesher from chunks. Mesher creating now should be handled by the world itself in _create_chunk. This makes worlds able to use different chunk mesher setups for different parts of a world. Also this cust down the amount of classes that you need to create if you are implementing a new mesher. 2020-10-06 19:43:49 +02:00
eb1d55f05b More work on the logic, and api fixes. 2020-10-03 17:18:43 +02:00
235943f7ca Removed the old meshing implementation, and replaced most logic to the new one. The code compiles, but it won't work for now. Also other cleanups. 2020-10-02 23:47:39 +02:00
3f04002453 Fix errors with bindings 2020-10-02 12:24:00 +02:00
71f69666cd Moved VoxelJob to a new folder. Also added generate_ao and generate_random_ao from voxel chunk into it. 2020-10-01 20:18:43 +02:00
142809d0cb Add an alternative type and isolevel to the default channels enum. 2020-08-21 20:02:47 +02:00
5358c99646 Now VoxelChunkDefault supports coloring MeshDataResources that span multiple chunks. 2020-08-16 18:20:16 +02:00
d8cf2af059 Same change to BUILD_PHASE_MESH_DATA_RESOURCES aswell. 2020-08-04 15:36:03 +02:00
6af711322d BUILD_PHASE_TERRARIN_MESH now can also distribute it's calculations onto multiple frames. 2020-08-04 15:30:34 +02:00
469927cc3b Now BUILD_PHASE_COLLIDER, and BUILD_PHASE_LIGHTS can both distribute their work onto multiple frames. 2020-08-04 14:53:10 +02:00
0a4d07c582 The terrarin mesh setup phase can now distribute it's calculations onto multiple frames.. Also small fixes to the single threaded logic. 2020-08-04 14:40:40 +02:00
b0a888d595 Removed limit execution time, and made everything a simple stub when ThreadPool is not present. 2020-08-04 10:52:27 +02:00
f1bee24803 Set start time in execute(). 2020-08-04 10:21:01 +02:00
919620031b Fix compile if ThreadPool is not present. 2020-08-04 10:08:04 +02:00
10b588f576 Cancel the job if complete is false. 2020-08-04 09:51:16 +02:00
bf58b94a99 Removed the thread from VoxelChunkDefault. 2020-08-04 09:49:40 +02:00
cff203fc49 Now the threading is handled by ThreadPool. 2020-08-04 09:44:18 +02:00
b95f055acd Add lod falloff property to VoxelWorldDefault. Also improved _update_lods(). 2020-08-03 19:05:40 +02:00
768728139e Fix compile for 4.0. 2020-07-29 00:02:42 +02:00
698f6083ea Add MESH_DATA_RESOURCE_PRESENT around a piece of code. 2020-07-18 14:19:13 +02:00
18ad178b1e Moved the create_meshers call from BUILD_PHASE_SETUP to _build. This causes it to run on the main thread. This is the first time I got a crash related to this, also the engine docs suggests that only scenetree manipulation is unsafe from threads, so this might have been caused by something else. 2020-07-18 13:12:29 +02:00
5ee5b12a4e Update _bake_light in VoxelChunkDefault to use the new apis. 2020-07-07 17:35:44 +02:00
6f7c4fbc8a Removed VoxelChunkPropData, the api of VoxelWorld, and VoxelChunk now uses PropDatas directly. 2020-07-07 01:06:46 +02:00
1355c301e8 Update draw_debug_mdr_colliders's logic to use the new api. Also fix error spam when a mesh data doens't have a collider. 2020-06-30 20:28:37 +02:00
3190217284 Moved simple collider storage from VoxelChunkDefault to VoxelChunk and separated it from the mesh data resource api. 2020-06-30 18:55:50 +02:00
138614f743 Update MeshDataResource offsets, as now they are Transforms. 2020-06-30 15:24:11 +02:00
a4b5400a4e Fix debug collider offsets. 2020-06-30 15:10:48 +02:00
7777056af3 Fix collider transform. 2020-06-30 11:59:22 +02:00
bb2f13b075 Small improvements. Also added commented out code for debugging the terrarin meshes (They will need to be converted be lines). 2020-06-29 23:44:54 +02:00
b54a1021d4 Moved away from using ImmediateGeometry for debug meshes. Also implemented debugging mdr colliders. 2020-06-29 23:08:52 +02:00
2e69796d08 Implement collider transforms. 2020-06-28 21:55:00 +02:00
1996f60f0f Fix indexing. 2020-06-28 21:30:26 +02:00
21d135fb0b Now chunk can only have one prop mesher. 2020-06-28 20:04:40 +02:00