Naxela / The_Lightmapper

Fast and easy baked GI Lightmaps for Blender and Cycles
GNU General Public License v3.0
690 stars 52 forks source link

Not sure TLM works with Blender 3.0 #143

Open kitaedesigns opened 2 years ago

kitaedesigns commented 2 years ago

This Error message appears when Building Lightmaps

" Python: Traceback (most recent call last): File "C:\Users\User\AppData\Roaming\Blender Foundation\Blender\3.0\scripts\addons\thelightmapper\addon\operators\tlm.py", line 52, in invoke build.prepare_build(self, False) File "C:\Users\User\AppData\Roaming\Blender Foundation\Blender\3.0\scripts\addons\thelightmapper\addon\utility\build.py", line 91, in prepare_build prepare.init(self, previous_settings) File "C:\Users\User\AppData\Roaming\Blender Foundation\Blender\3.0\scripts\addons\thelightmapper\addon\utility\cycles\prepare.py", line 18, in init set_settings() File "C:\Users\User\AppData\Roaming\Blender Foundation\Blender\3.0\scripts\addons\thelightmapper\addon\utility\cycles\prepare.py", line 590, in set_settings scene.render.tile_x = 256 AttributeError: 'RenderSettings' object has no attribute 'tile_x'

location: :-1 "

Naxela commented 2 years ago

Hi, and thanks for reporting this bug!

I added a new release where I think this should be solved: https://github.com/Naxela/The_Lightmapper/releases/tag/0.6.12

Let me know if the problem still occurs

kitaedesigns commented 2 years ago

With the latest build I get this error when trying to install the plugin.

Traceback (most recent call last): File "C:\Program Files\Blender Foundation\Blender 3.0\3.0\scripts\modules\addon_utils.py", line 351, in enable mod = import(module_name) ModuleNotFoundError: No module named 'The_Lightmapper-0'

Naxela commented 2 years ago

Hi, I just updated the binaries in the build (https://github.com/Naxela/The_Lightmapper/releases/tag/0.6.12) so that the name error shouldn't occur - Are you using Blender 3.0 or Blender 3.1?

kitaedesigns commented 2 years ago

Currently using Blender 3.0. I will try the latest release again and see if maybe I'm doing something wrong but I have tried using the provided zip, also unzipping and zipping the addon folder within the plugin and it doesn't seem to be working.

Naxela commented 2 years ago

That's strange, by default it should recognize the correct folder at the start - If you go to the addon folder, does it have the same name as this?:

image

kitaedesigns commented 2 years ago

No mine has the specific lightmapper version in the file path. image

Naxela commented 2 years ago

I think that could be the reason. If you rename it to thelightmapper (with lowercase), does it still not work?

kitaedesigns commented 2 years ago

that seemed to do the trick! thanks!

Naxela commented 2 years ago

Usually I name the folder like that in the zip, but I think that in the previous zipped file I might have forgotten, which caused the error - Good to hear it's resolved!

kitaedesigns commented 2 years ago

Yes it seems to be working fine although is it normal for there to be .pfm files generated now? Not sure what these are. I was trying to use SDR Encoding to produce .png lightmaps but then these appeared.

image

Naxela commented 2 years ago

Hi, the .pfm files are completely normal. They are required by the Intel denoising (since it doens't support .hdr or .exr files). I'll add a cleaning function one of these days, but so far it's safe to delete those.

kitaedesigns commented 2 years ago

There seems to be a problem with the SDR Encoding option that gets confused with directories since so many files are being produced and the lightmap paths aren't correct resulting in missing textures in the shader graph image image

kitaedesigns commented 2 years ago

Seems to be some sort of problem with packed images in temporary memory. image

Naxela commented 2 years ago

That seems strange, so it seems to be caused by the combination of SDR encoding and packed images? - If you make a copy of the blend file and unpack the textures locally, does it work in that case?

kitaedesigns commented 2 years ago

Copying the project and unpacking doesn't seem to work. I think the problem is that the name of the texture being referenced in the shader does not match any of the texture names when Encoding with RGBD is enabled since the texture created in the shader is named "meshname__baked" it doesn't know which extension to use so it ends up being a missing reference. image

Naxela commented 2 years ago

Hi, thanks for investigating this! It sounds plausible that there could be some mismatch in terms of name and extension when the textures are being referenced, but I can't seem to reproduce it. I was wondering if you could share the packed scene (if you'd want it to be private, you could WeTransfer it with a link on Discord perhaps?)

Thanks again