YafaRay / Blender-Exporter

ARCHIVED-READ ONLY now. Use YafaRay-Blender repository instead. YafaRay's Blender Exporter
http://www.yafaray.org
63 stars 19 forks source link

SPPM integrator doesn't work #40

Closed odil24 closed 4 years ago

odil24 commented 4 years ago

Sometimes SPPM integrator doesn't working and Blender crash during first frame.

OS: WIN7 X64 CPU: C2Q Q6600 @2.4GHZ RAM:3GB DDR2 800MHZ YAFA 3.4.4 FOR BLENDER 2.79b

DavidBluecame commented 4 years ago

Hello,

Please will you provide an example blend file? Thanks.

odil24 commented 4 years ago

Ok. I will. But, i tested again the scene with carefuly and stocked on one solution:

Strange thing: a)what it does that properties and how to add that to another object? b)maybe after add that props to object the problem goes?

odil24 commented 4 years ago

here blend file: https://anonfiles.com/1fgcqf41ob/tulipwine_rar

NOTE: IF YOU RESTRICT "1-BOTTLEWINE" AND "2-CHAIR" FROM THE RENDER IMAGE SO BLENDER DONT CRASH, BUT IF YOU ENABLE THIS TWO OBJECTS PROBLEM HAS APPEARED DURING RENDERING AND BLEND WILL CRASH.

odil24 commented 4 years ago

EDIT2: The problems are aimed from this too I think (you can just testing with this): https://developer.blender.org/T63068

DavidBluecame commented 4 years ago

Hello,

I could replicate the issue in Windows 10 64bit, but it does not happen in Linux Fedora 64bit for example, weird...

I'll try to locate the root cause, but it's not easy to find this kind of memory corruption... Anyway I'll chase it, thanks for reporting it! :-)

odil24 commented 4 years ago

Hi again. I think 90% that it is related to Autosmooth/Normals (Geometry data: Create custom normal) options:

  1. I opened this has been attached blend file again.
  2. Go to "buggy object".
  3. Selected them.
  4. Go to 🔺(Autosmooth, Uv, Shape panel).
  5. Enable Autosmooth and set to value 60°.
  6. Go below Geometry data toolset and create/cleared custom normal.
  7. Go to Export option under main menu of 3d view mode.
  8. Export it as OBJ with this setups: -disable edge; -disable normals -enable selected only (must for exporting "buggy object".
  9. After that, delete "buggy object" and import that Obj exported again into the scene.
  10. Now the bug must be disappeared afther this steps.

Maybe, can you try this?

DavidBluecame commented 4 years ago

Hello,

Not an easy one, I'm afraid, but I think I've found the root cause in the SPPM algorithm looking to a negative array index when some coordinates are negative. I need to see how to fix it, though.

Fortunately I think I can give you a workaround that should solve the issue for now. Please try this:

I hope it helps. I hope that changing the Shift X parameter does not alter the scene in a significant way for you and that it resolves the issue.

I'm not closing this for now as I have to find out how to properly fix it in the code, but please let me know if the workaround helps.

odil24 commented 4 years ago

Hello, David. Sorry for late post. I've tried as you wrote me step by step instructions. And yeah, it was works here now. The main problem was not been in NEGATIVE VALUE OF CAMER SHIFT, but also exactly on Camera/Shift itself. True or Negative value isnt working in SPPM integrator. So, i will close this issue here and open new one as "Camera tile shift isn't supported by SPPM integrator":

DavidBluecame commented 4 years ago

Hello, I've added some code to fix this. This should be fixed in the next release v3.5.0