Random Chitchat 2020-2024
#52
(08-23-2020, 04:15 PM)xoft Wrote: There are multiple caches in the worldgen - biome cache, height cache, composition cache. Getting rid of them would be unwise, they save a LOT of work. For example the biome cache measured more than 90 % cache hit rate during startup world generation - that means ~10x speedup just thanks to the cache.

If I remember correctly, the terrain height is used in trees generator to see if the trunk and branches (all log blocks, in fact) intersect the terrain, if not, the tree is not generated; for this to work, it needs to see into the neighboring chunk as well (bent acacia trees' trunks and branches may go off-chunk). So no, it can't be removed, otherwise you end up with tree parts on chunk borders that generate in one chunk but don't generate in the other chunk. Can you imagine how long this took to actually get right? Smile

If you want to threadpool the worldgen, you need to make the caches thread-safe and share them among all the threads / tasks.

That's a very helpful explanation, thank you.

I did some testing and after villages and trees are commented out the only thing that hits a cache is apparently height generation, reading 3x3 chunks' worth of biome data. This is to smooth out height transitions between biomes, right? Reminds me of the lighting thread, that also has a 9:1 read amplification when calculating one chunk xD

Do you think it would be, theoretically, feasible to generate the terrain first, say with suitably tuned 3D noise, and afterwards retroactively apply biomes based on the terrain height, a temperature map, and a humidity map? This way we can sidestep needing to smooth out height.
Reply
Thanks given by:


Messages In This Thread
Random Chitchat 2020-2024 - by xoft - 01-02-2020, 04:35 AM
RE: Random Chitchat 2020 - by tonibm19 - 01-02-2020, 04:45 AM
RE: Random Chitchat 2020 - by xoft - 01-02-2020, 04:55 AM
RE: Random Chitchat 2020 - by tonibm19 - 01-02-2020, 04:58 AM
RE: Random Chitchat 2020 - by xoft - 01-31-2020, 10:36 PM
RE: Random Chitchat 2020 - by xoft - 02-23-2020, 06:41 PM
RE: Random Chitchat 2020 - by Mathias - 02-23-2020, 09:13 PM
RE: Random Chitchat 2020 - by xoft - 02-26-2020, 09:15 AM
RE: Random Chitchat 2020 - by Mathias - 03-16-2020, 05:28 PM
RE: Random Chitchat 2020 - by tigerw - 03-20-2020, 01:59 AM
RE: Random Chitchat 2020 - by Mathias - 03-20-2020, 03:18 AM
RE: Random Chitchat 2020 - by NiLSPACE - 03-20-2020, 04:10 AM
RE: Random Chitchat 2020 - by xoft - 03-20-2020, 05:33 AM
RE: Random Chitchat 2020 - by xoft - 03-28-2020, 06:30 PM
RE: Random Chitchat 2020 - by Seadragon91 - 03-22-2020, 05:50 PM
RE: Random Chitchat 2020 - by Mathias - 03-22-2020, 07:39 PM
RE: Random Chitchat 2020 - by xoft - 03-22-2020, 07:39 PM
RE: Random Chitchat 2020 - by Mathias - 03-22-2020, 07:42 PM
RE: Random Chitchat 2020 - by Mathias - 03-22-2020, 07:49 PM
RE: Random Chitchat 2020 - by bearbin - 03-23-2020, 10:45 PM
RE: Random Chitchat 2020 - by bearbin - 03-25-2020, 07:45 AM
RE: Random Chitchat 2020 - by tigerw - 03-28-2020, 10:54 AM
RE: Random Chitchat 2020 - by ThuGie - 03-29-2020, 11:59 AM
RE: Random Chitchat 2020 - by tigerw - 03-31-2020, 10:06 PM
RE: Random Chitchat 2020 - by xoft - 04-01-2020, 01:26 AM
RE: Random Chitchat 2020 - by xoft - 04-22-2020, 06:37 PM
RE: Random Chitchat 2020 - by tigerw - 04-23-2020, 03:43 AM
RE: Random Chitchat 2020 - by xoft - 04-23-2020, 06:35 AM
RE: Random Chitchat 2020 - by tigerw - 04-23-2020, 07:38 AM
RE: Random Chitchat 2020 - by xoft - 04-24-2020, 04:30 PM
RE: Random Chitchat 2020 - by ThuGie - 04-25-2020, 07:21 AM
RE: Random Chitchat 2020 - by xoft - 05-12-2020, 02:54 AM
RE: Random Chitchat 2020 - by Greaper88 - 05-12-2020, 04:06 AM
RE: Random Chitchat 2020 - by tigerw - 06-18-2020, 07:42 AM
RE: Random Chitchat 2020 - by tigerw - 06-24-2020, 09:32 AM
RE: Random Chitchat 2020 - by xoft - 06-24-2020, 04:49 PM
RE: Random Chitchat 2020 - by Mathias - 08-03-2020, 10:22 AM
RE: Random Chitchat 2020 - by tigerw - 08-13-2020, 03:45 AM
RE: Random Chitchat 2020 - by NiLSPACE - 08-13-2020, 04:35 AM
RE: Random Chitchat 2020 - by xoft - 08-13-2020, 07:33 AM
RE: Random Chitchat 2020 - by tigerw - 08-21-2020, 03:24 AM
RE: Random Chitchat 2020 - by Greaper88 - 08-21-2020, 03:32 AM
RE: Random Chitchat 2020 - by tigerw - 08-21-2020, 03:53 AM
RE: Random Chitchat 2020 - by xoft - 08-21-2020, 10:20 PM
RE: Random Chitchat 2020 - by NiLSPACE - 08-22-2020, 06:29 PM
RE: Random Chitchat 2020 - by xoft - 08-23-2020, 04:14 AM
RE: Random Chitchat 2020 - by tigerw - 08-23-2020, 10:37 AM
RE: Random Chitchat 2020 - by xoft - 08-23-2020, 04:15 PM
RE: Random Chitchat 2020 - by tigerw - 08-23-2020, 11:27 PM
RE: Random Chitchat 2020 - by xoft - 08-23-2020, 09:07 PM
RE: Random Chitchat 2020 - by Greaper88 - 08-23-2020, 09:16 PM
RE: Random Chitchat 2020 - by Greaper88 - 08-23-2020, 09:25 PM
RE: Random Chitchat 2020 - by tigerw - 08-23-2020, 11:31 PM
RE: Random Chitchat 2020 - by tigerw - 08-23-2020, 11:36 PM
RE: Random Chitchat 2020 - by NiLSPACE - 08-24-2020, 12:16 AM
RE: Random Chitchat 2020 - by tigerw - 08-24-2020, 01:13 AM
RE: Random Chitchat 2020 - by NiLSPACE - 08-24-2020, 05:23 PM
RE: Random Chitchat 2020 - by xoft - 08-24-2020, 01:23 AM
RE: Random Chitchat 2020 - by tigerw - 08-24-2020, 02:07 AM
RE: Random Chitchat 2020 - by xoft - 08-24-2020, 05:08 PM
RE: Random Chitchat 2020 - by tigerw - 08-30-2020, 09:20 AM
RE: Random Chitchat 2020 - by tonibm19 - 09-07-2020, 07:30 AM
RE: Random Chitchat 2020 - by xoft - 09-07-2020, 07:20 PM
RE: Random Chitchat 2020 - by xoft - 09-13-2020, 09:00 AM
RE: Random Chitchat 2020 - by Mathias - 09-14-2020, 02:23 AM
RE: Random Chitchat 2020 - by tigerw - 09-14-2020, 04:57 AM
RE: Random Chitchat 2020 - by tigerw - 10-31-2020, 11:20 PM
RE: Random Chitchat 2020 - by tigerw - 12-26-2020, 08:59 PM
RE: Random Chitchat 2020 - by NiLSPACE - 12-26-2020, 09:07 PM
RE: Random Chitchat 2020 - by ThuGie - 12-27-2020, 09:49 AM
RE: Random Chitchat 2020 - by tigerw - 01-01-2021, 03:42 AM
RE: Random Chitchat 2020 - by NiLSPACE - 01-01-2021, 04:15 AM
RE: Random Chitchat 2020 - by Seadragon91 - 01-01-2021, 06:38 AM
RE: Random Chitchat 2020 - by tigerw - 01-11-2021, 10:32 AM
RE: Random Chitchat 2020-2021 - by Mathias - 02-19-2021, 07:41 AM
RE: Random Chitchat 2020-2021 - by tigerw - 12-25-2021, 11:54 PM
RE: Random Chitchat 2020-2021 - by NiLSPACE - 12-26-2021, 12:06 AM
RE: Random Chitchat 2020-2021 - by bearbin - 12-26-2021, 09:28 AM
RE: Random Chitchat 2020-2021 - by xoft - 01-21-2022, 11:57 PM
RE: Random Chitchat 2020-2021 - by NiLSPACE - 01-22-2022, 12:17 AM
RE: Random Chitchat 2020-2021 - by xoft - 01-29-2022, 09:15 AM
RE: Random Chitchat 2020-2021 - by NiLSPACE - 01-29-2022, 09:36 AM
RE: Random Chitchat 2020-2021 - by Mathias - 02-05-2022, 01:09 PM
RE: Random Chitchat 2020-2021 - by tigerw - 12-25-2022, 11:36 PM
RE: Random Chitchat 2020-2021 - by NiLSPACE - 12-26-2022, 07:49 AM
RE: Random Chitchat 2020-2021 - by xoft - 12-26-2022, 07:54 AM
RE: Random Chitchat 2020-2021 - by NiLSPACE - 01-01-2023, 09:26 AM
RE: Random Chitchat 2020-2021 - by xoft - 01-01-2023, 07:29 PM
RE: Random Chitchat 2020-2021 - by Mathias - 05-11-2023, 01:36 AM
RE: Random Chitchat 2020-2023 - by NiLSPACE - 06-05-2023, 07:19 AM
RE: Random Chitchat 2020-2023 - by xoft - 06-20-2023, 07:34 PM
RE: Random Chitchat 2020-2023 - by xoft - 11-18-2023, 05:23 AM
RE: Random Chitchat 2020-2023 - by NiLSPACE - 11-18-2023, 06:08 AM
RE: Random Chitchat 2020-2023 - by tigerw - 12-25-2023, 09:37 AM
RE: Random Chitchat 2020-2023 - by dxomgmyfriend - 12-25-2023, 11:47 AM
RE: Random Chitchat 2020-2023 - by NiLSPACE - 12-25-2023, 11:59 PM
RE: Random Chitchat 2020-2023 - by tigerw - 01-01-2024, 06:56 AM
RE: Random Chitchat 2020-2023 - by NiLSPACE - 01-01-2024, 09:31 AM
RE: Random Chitchat 2020-2023 - by xoft - 02-19-2024, 08:29 AM
RE: Random Chitchat 2020-2023 - by 12xx12 - 02-19-2024, 10:15 PM
RE: Random Chitchat 2020-2023 - by NiLSPACE - 02-19-2024, 08:47 AM
RE: Random Chitchat 2020-2024 - by xoft - 03-05-2024, 07:51 AM
RE: Random Chitchat 2020-2024 - by NiLSPACE - 03-05-2024, 08:22 AM
RE: Random Chitchat 2020-2024 - by Mathias - 03-06-2024, 08:00 AM
RE: Random Chitchat 2020-2024 - by xoft - 03-08-2024, 09:58 PM
RE: Random Chitchat 2020-2024 - by Mathias - 03-10-2024, 05:59 AM
RE: Random Chitchat 2020-2024 - by xoft - 03-11-2024, 07:32 PM
RE: Random Chitchat 2020-2024 - by NiLSPACE - 03-11-2024, 07:50 PM
RE: Random Chitchat 2020-2024 - by 12xx12 - 03-11-2024, 08:31 PM
RE: Random Chitchat 2020-2024 - by xoft - 03-11-2024, 09:00 PM
RE: Random Chitchat 2020-2024 - by Mathias - 03-13-2024, 08:23 AM
RE: Random Chitchat 2020-2024 - by Mathias - 06-20-2024, 05:20 AM
RE: Random Chitchat 2020-2024 - by bearbin - 06-20-2024, 05:57 AM
RE: Random Chitchat 2020-2024 - by xoft - 06-24-2024, 06:08 AM
RE: Random Chitchat 2020-2024 - by NiLSPACE - 06-24-2024, 06:34 AM
RE: Random Chitchat 2020-2024 - by Mathias - 06-29-2024, 01:15 AM



Users browsing this thread: 18 Guest(s)