Marc Gilleron
4ec60074bb
Refactor generators and streams
...
- VoxelGenerator no longer inherit VoxelStream
- VoxelStream is now more focused on files
- Nodes have separate stream and generator properties
- Generators use 2 dedicated threads instead of sharing a single one with streams
- TODO Image.lock() is problematic for multithreading
- TODO Voxel graph can cause RWLock contention if edited while it runs
- TODO Saving generator output no longer works, need to put it back
2021-01-17 17:18:05 +00:00
Marc Gilleron
fb1442e444
Fix constants not reset between two prepares, caused broken terrain after changing the generator
2021-01-17 16:58:56 +00:00
Marc Gilleron
7940b3b761
Made VoxelGeneratorGraph thread-safe
2021-01-16 13:51:01 +00:00
Marc Gilleron
a96a377953
Fix reference to temporary I guess, detected by GCC only
2021-01-09 20:23:51 +00:00
Marc Gilleron
22bd0d5091
Fix shadowing issue, also inlined function used in only one place
2021-01-09 20:22:37 +00:00
Marc Gilleron
93b4e6803a
Remove unused variables
2021-01-09 20:21:51 +00:00
Marc Gilleron
3a7f99643d
Fix more signed/unsigned warnings
2021-01-09 20:21:09 +00:00
Marc Gilleron
4686735f00
Fix pseudo-shadowing detected by GCC
2021-01-09 19:51:58 +00:00
Marc Gilleron
cf83aca282
Fix signed/unsigned comparisons
2021-01-09 19:49:11 +00:00
Marc Gilleron
494512a424
Fix initialization order
2021-01-09 19:34:03 +00:00
Marc Gilleron
1bb3d19e03
Use buffers to generate previews
2021-01-09 18:35:53 +00:00
Marc Gilleron
b2ca66e714
Fix Smoothstep node, params were not initialized
2021-01-09 16:36:09 +00:00
Marc Gilleron
1e95374ccb
The graph runtime now suports arbitrary position buffers, instead of an XZ rectangle
2021-01-08 21:04:49 +00:00
Marc Gilleron
04c1d61cd2
Quick cleanup, also patch preview nodes
2021-01-07 23:36:14 +00:00
Marc Gilleron
e00ed9b538
Move all node logic to function pointers, each combined into one place
2021-01-07 22:19:06 +00:00
Marc Gilleron
2cfa46bf0d
Removed wrong bound estimation for value cubic noise, it caused rare but ugly gliches in the terrain
2021-01-07 21:02:24 +00:00
Marc Gilleron
4a290f27c0
Removed bounds support, it not really relevant anymore
2021-01-05 22:24:13 +00:00
Marc Gilleron
825fa4147b
Main graph generator now uses buffers for blocks
2021-01-05 18:59:52 +00:00
Marc Gilleron
15fe9ecdeb
Fix Wrong position buffer when stride is 1
2021-01-05 18:57:30 +00:00
Marc Gilleron
dafb4f39ff
First WIP to try per-buffer processing instead of per-voxel
2021-01-04 22:19:13 +00:00
Marc Gilleron
3364748fef
Integrate FastNoiseLite to voxel graph generator
2021-01-03 20:23:45 +00:00
Marc Gilleron
3e31140ed8
Bind missing constant for the Normalize3D node
2021-01-02 00:58:01 +00:00
Marc Gilleron
394a123bb7
Fixed Clamp node, it was using parameters as adresses
2021-01-01 01:43:46 +00:00
Marc Gilleron
d64340aa73
Small optimization in Remap node
2020-12-29 22:12:31 +00:00
Marc Gilleron
edfc96e4a5
Fixed crash when hiding terrain while selected in editor
2020-12-27 15:51:03 +00:00
Marc Gilleron
57fac6c5b1
Fix GCC warning
2020-12-26 19:01:49 +00:00
Marc Gilleron
e462cd788a
Optimized range analysis for images and spherical map lookups
2020-12-26 18:58:16 +00:00
Marc Gilleron
9e423a58f7
Voxel graph optimizations:
...
- Dynamically adjust SDF scaling to reduce terracing caused by storage resolution
- Optimize range analysis more aggressively
2020-12-24 23:16:34 +00:00
Marc Gilleron
d009049d4f
Added experimental functions to bake sphere maps from the generator
...
- The runtime API now works with float positions
- Fixed XZ optimization, cached positions were not assigned
2020-12-22 02:13:46 +00:00
Marc Gilleron
7c6bfe0dbc
Added Normalize node to voxel graph
2020-12-21 20:06:20 +00:00
Marc Gilleron
ae9abb0248
Added SdfSphereHeightmap node to graph generator
2020-12-21 02:00:31 +00:00
Marc Gilleron
510d25e604
Expose find_node_by_name
2020-10-29 00:42:55 +00:00
Marc Gilleron
44a1af2043
Don't crash if graph resources are null
2020-10-26 19:58:54 +00:00
Marc Gilleron
56b4b55b53
Fix missing return
2020-10-25 23:07:53 +00:00
Marc Gilleron
61f17ce96d
Formatting
2020-10-25 20:38:23 +00:00
Marc Gilleron
b672013f00
Fix an occurrence of Variant uint64_t ambiguity for Mac builds
2020-10-25 20:27:09 +00:00
Marc Gilleron
0cb8188eb7
Added ability to name graph nodes
2020-10-25 20:26:25 +00:00
Marc Gilleron
d158a92f57
Show bounds and octrees of VoxelLodTerrain with debug drawing
2020-10-24 00:08:14 +01:00
Marc Gilleron
7405692f68
Unused code
2020-09-07 23:53:38 +01:00
Marc Gilleron
23ce65d789
Show terrain in editor, with option to turn it off. A scripted stream will turn it off by default.
2020-08-14 20:33:09 +01:00
menip
e64f5f882c
Fix warnings
...
Wparentheses
Wsign-compare
Wreorder
2020-08-01 22:03:26 -07:00
Marc Gilleron
bc7ec0c966
Use last found SDF output and don't crash when there isn't any
2020-07-11 17:03:58 +01:00
Marc Gilleron
56aee87615
Added Select node to "conditionally" switch between two values
2020-07-11 17:03:09 +01:00
Marc Gilleron
0cac00e501
Fix preview nodes not working if they are the only output from their ancestor
2020-07-11 17:01:34 +01:00
Marc Gilleron
72c970e182
Alternate positions when profiling a graph to avoid XYZ optimization bias
2020-07-11 16:57:41 +01:00
Marc Gilleron
1cd0a491bb
Fix graph not working if there is more than one terminal node (preview nodes)
2020-07-11 16:56:37 +01:00
Marc Gilleron
38aeb6959d
Use C++ limits to be consistent with Interval
2020-07-11 03:24:32 +01:00
Marc Gilleron
1a08cd31d6
Use a macro to print debug stuff only in verbose mode
2020-07-08 20:48:52 +01:00
Marc Gilleron
6b63746135
Added categories
2020-07-08 01:26:12 +01:00
Marc Gilleron
b8c235fce3
Added preview nodes (has a few limitations, may fix them later)
2020-07-07 23:28:02 +01:00