Open BielBdeLuna opened 3 years ago
Maybe you ran out of main memory so the OOM killer kicked in? => run rbdoom3bfg in windowed mode and keep an eye memory consumption while running the command. top or htop should help.
and probably dmesg or the syslog will have an entry if the OOM killer was active
Actually there is no real fixed size limit like in Quake 3 even there MAX_AREA_LIGHTGRID_POINTS. It's only a suggestion or default limit which can be overridden by bakeLightGrids limit1000 or bakeLightGrids limit20000. However you probably ran out of memory by allocating 15895 cubemaps with the size of 256256632 (RGB16F) which is 35763.75 MB. I still need to break up the algorithm that it only captures 2000 probes in a single step.
yeah, my computer has 16 Gigs and since it's using all the cores the computer locks up while it's working, by that time the RAM usage of RBDoom3BFG is 13Gb so I bet when it reaches around max ram it fails out.
maybe when the area of the light grid is too great maybe the part could be separated in two parts, create two different atlases, and then add them in a single larger atlas, only once you've finished baking them up, and the memory is flushed, so you could have n atlases per light grid area, and so have light grid areas that are larger with lots of grid points.
edit--- with the limit set to 6000 is my limit for the mars_city, with it RBDoom3BFG never goes over 12GBs of RAM, since I'm seeing Hell1 is the biggest light grid you distributed I'm going to find the best Limit value for Hell1 and 16 GBs of RAM
edit 2 --- for Hell I have to go as low as limit set to 5000, but Hell1 having the larger file doesn't mean that it represents anything, it might aggregate to the biggest file because it has so many small rooms full of grid points, but the problem of RAM is a per-room problem, so the bigger the room the more grid points, maybe Enpro has bigger rooms? or maybe the Hell_hole cyberdemon arena is the biggest room? or maybe the LE hell maps?
edit 3-- I think the biggest map in terms of having lots of big rooms is le_hell map, and I could bake the light grid with a limit 5000 using 16GBs of memory
the sigkill happens during the envprobe image capture, why not save every row of the lightgrid (as I see those get capture in rows or stages instead of collumns ) as a separate exr image, and once captured, splice all the row exr images in a single exr for the whole lightgrid, and then do the convolution as normal, therefore we should be able to capture higher lightgrid density and be less prone to run out of memory due that we don't keep it all in RAM at the same time but in disk.
I can confirm this i think its related with some new structure stuff Cannot run anymore on a board with 2GB doom3 memory cause SIGKILL in loading screen but on the same board with 4GB can load fine . This problem is not affected by DOOM1 or DOOM2.
while baking the mars_city map I get a SIGKILL without further trace
in area 2 of 56, it has a huge number of grid points 15895 ( to close to the limit maybe? )