Page 4 of 6

Re: Two well known luxcore problems.

Posted: Mon Aug 30, 2021 11:22 pm
by Dade
daros wrote: Mon Aug 30, 2021 9:53 pm Do you think you can do anything to reduce this halo on bidir?
It is a BiDir-only only problem and it is likely to be related to some wrong PDF (i.e. the weight of the mix between light tracing and path tracing). I'm looking into it (but it is quite complicated stuff).

Re: Two well known luxcore problems.

Posted: Tue Aug 31, 2021 7:53 am
by Sharlybg
The fact that you know the source of the issue is a great progress by itself.

Re: Two well known luxcore problems.

Posted: Wed Sep 01, 2021 9:15 am
by Dade
I should have fixed the problem, this is a rendering with old code:

bidir1.jpg

and with the new code:

bidir2.jpg

Note how the fix doesn't affect only the edge but the overall look of the material.

Re: Two well known luxcore problems.

Posted: Wed Sep 01, 2021 9:43 am
by Sharlybg
Congrats Dade !
Btw can we just download the last build and test it ?

Re: Two well known luxcore problems.

Posted: Wed Sep 01, 2021 11:38 am
by chuchur
Hi Dade! Thank you for fixing it!

Was it the main reason?

Code: Select all

	if (directPdfW || reversePdfW) {
		const float pdf = DisneyPdf(roughness, metallic, clearcoat, clearcoatGloss,
				anisotropicGloss, localLightDir, localEyeDir);

		if (pdf < 0.0001f)
			return Spectrum();

		if (directPdfW)
			*directPdfW = pdf;
		if (reversePdfW)
			*reversePdfW = pdf;
	}
	
I will try to merge it with my changes :)

Re: Two well known luxcore problems.

Posted: Wed Sep 01, 2021 11:41 am
by daros
I don't know if this helps.
Those are real world samples of exactly the same set-up

Lime only, spehere and box.
lime.jpg

Lime only+transparent lacquer, spehere only
lime+transparent lacquer.jpg

enameled cermic, spehere only
ceramic.jpg


Tone mapping of the photos is linear, no highlight compression, almost pure RAW, only white blance, camera Sony Alpha 7 III with 50mm Zeiss lenses.

Re: Two well known luxcore problems.

Posted: Wed Sep 01, 2021 12:31 pm
by kintuX
daros wrote: Wed Sep 01, 2021 11:41 am I don't know if this helps.
Those are real world samples of exactly the same set-up

Lime only, spehere and box.
lime.jpg


Lime only+transparent lacquer, spehere only
lime+transparent lacquer.jpg


enameled cermic, spehere only
ceramic.jpg



Tone mapping of the photos is linear, no highlight compression, almost pure RAW, only white blance, camera Sony Alpha 7 III with 50mm Zeiss lenses.
Could you share the lighting setup (diagram & full specs, if possible)? Unless you already recreated it digitally (1:1), then scene file would be most welcome... ;) appreciated!

PS
Also, did you took those with macbeth colorchart for color correctness? I wonder cuz of warm tone...

Re: Two well known luxcore problems.

Posted: Wed Sep 01, 2021 12:45 pm
by daros
It's the same scene which has been shared by Sharlybg on page 3.

Fstop 22, shutter 1/10, iso 100, focus at the front of the sphere, camera position in the center of the hole of the backwall

White balance is the same for all materials we sampled, so some show up warmer and others colder.

Re: Two well known luxcore problems.

Posted: Wed Sep 01, 2021 2:11 pm
by Dade
chuchur wrote: Wed Sep 01, 2021 11:38 am Was it the main reason?
There were a couple of problems but the main reason was this: https://github.com/LuxCoreRender/LuxCor ... y.cpp#L115

It is an old JeanPhi's idea: it is correct but it always slip under the radar of anyone not used to Lux code (i.e. the original Disney material code was written by a guy for his thesis a while ago and submitted as patch).

Re: Two well known luxcore problems.

Posted: Wed Sep 01, 2021 3:09 pm
by chuchur
Hi Dade,

I've tried to merge, but now I've got a strange linker problem by building luxcoreconsole:

I can build slg-core.lib without a problem.

Sorry, just running cmake has helped :)

Code: Select all

slg-core.lib(scene.obj) : error LNK2019: unresolved external symbol "public: static class slg::ImageMapResizePolicy * __cdecl slg::ImageMapResizePolicy::FromProperties(class luxrays::Properties const &)" (?FromProperties@ImageMapResizePolicy@slg@@SAPEAV12@AEBVProperties@luxrays@@@Z) referenced in function "private: void __cdecl slg::Scene::Init(class luxrays::Properties const *)" (?Init@Scene@slg@@AEAAXPEBVProperties@luxrays@@@Z)
2>slg-core.lib(imagemapcache.obj) : error LNK2001: unresolved external symbol "public: virtual class slg::ImageMap * __cdecl slg::ImageMapResizeNonePolicy::ApplyResizePolicy(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class slg::ImageMapConfig const &,bool &)const " (?ApplyResizePolicy@ImageMapResizeNonePolicy@slg@@UEBAPEAVImageMap@2@AEBV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@AEBVImageMapConfig@2@AEA_N@Z)
2>slg-core.lib(imagemapcacheserialize.obj) : error LNK2001: unresolved external symbol "public: virtual class slg::ImageMap * __cdecl slg::ImageMapResizeNonePolicy::ApplyResizePolicy(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class slg::ImageMapConfig const &,bool &)const " (?ApplyResizePolicy@ImageMapResizeNonePolicy@slg@@UEBAPEAVImageMap@2@AEBV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@AEBVImageMapConfig@2@AEA_N@Z)
2>slg-core.lib(parseshapes.obj) : error LNK2019: unresolved external symbol "public: __cdecl slg::CameraProjUVShape::CameraProjUVShape(class luxrays::ExtTriangleMesh *,unsigned int)" (??0CameraProjUVShape@slg@@QEAA@PEAVExtTriangleMesh@luxrays@@I@Z) referenced in function "private: class luxrays::ExtTriangleMesh * __cdecl slg::Scene::CreateShape(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class luxrays::Properties const &)" (?CreateShape@Scene@slg@@AEAAPEAVExtTriangleMesh@luxrays@@AEBV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@AEBVProperties@4@@Z)
2>slg-core.lib(imagemapcacheserialize.obj) : error LNK2001: unresolved external symbol "public: virtual class slg::ImageMap * __cdecl slg::ImageMapResizeFixedPolicy::ApplyResizePolicy(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,class slg::ImageMapConfig const &,bool &)const " (?ApplyResizePolicy@ImageMapResizeFixedPolicy@slg@@UEBAPEAVImageMap@2@AEBV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@AEBVImageMapConfig@2@AEA_N@Z)