Compiling on Linux

Discussion related to the Engine functionality, implementations and API.
neo2068
Developer
Posts: 86
Joined: Tue Dec 05, 2017 6:06 pm

Re: Compiling on Linux

Post by neo2068 » Sat Jun 09, 2018 9:12 pm

Dade wrote:
Sat Jun 09, 2018 6:52 pm
Does it happen also with official binaries ? It could be the Blender international font settings :?:
No, it only happens with my build.

This is what ldd pyluxcore.so gives.
official release in BlendLuxCore-v2.1alpha1-linux64:

Code: Select all

	linux-vdso.so.1 =>  (0x00007ffdd7fe5000)
	libembree3.so.3 => /home/michael/.config/blender/2.79/scripts/addons/BlendLuxCore/bin/./libembree3.so.3 (0x00007f818731e000)
	libtbb.so.2 => /home/michael/.config/blender/2.79/scripts/addons/BlendLuxCore/bin/./libtbb.so.2 (0x00007f81870c3000)
	libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007f8186ea6000)
	libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007f8186b9d000)
	libgomp.so.1 => /usr/lib/x86_64-linux-gnu/libgomp.so.1 (0x00007f818697b000)
	libgcc_s.so.1 => /lib/x86_64-linux-gnu/libgcc_s.so.1 (0x00007f8186765000)
	libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f818639b000)
	/lib64/ld-linux-x86-64.so.2 (0x00007f818b941000)
	libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007f8186197000)
	libtbbmalloc.so.2 => /home/michael/.config/blender/2.79/scripts/addons/BlendLuxCore/bin/./libtbbmalloc.so.2 (0x00007f8185f40000)
	libstdc++.so.6 => /usr/lib/x86_64-linux-gnu/libstdc++.so.6 (0x00007f8185bbe000)
	librt.so.1 => /lib/x86_64-linux-gnu/librt.so.1 (0x00007f81859b6000)
my build of tag luxcorerender_v2.1alpha1:

Code: Select all

	linux-vdso.so.1 =>  (0x00007ffe5d79d000)
	libembree3.so.3 => /home/michael/.config/blender/2.79/scripts/addons/BlendLuxCore/bin/libembree3.so.3 (0x00007fae7b265000)
	libtbb.so.2 => /home/michael/.config/blender/2.79/scripts/addons/BlendLuxCore/bin/libtbb.so.2 (0x00007fae7b00a000)
	libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007fae7aded000)
	libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007fae7aae4000)
	libgomp.so.1 => /usr/lib/x86_64-linux-gnu/libgomp.so.1 (0x00007fae7a8c2000)
	libgcc_s.so.1 => /lib/x86_64-linux-gnu/libgcc_s.so.1 (0x00007fae7a6ac000)
	libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007fae7a2e2000)
	/lib64/ld-linux-x86-64.so.2 (0x00007fae7f9c2000)
	libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007fae7a0de000)
	libtbbmalloc.so.2 => /home/michael/.config/blender/2.79/scripts/addons/BlendLuxCore/bin/libtbbmalloc.so.2 (0x00007fae79e87000)
	libstdc++.so.6 => /usr/lib/x86_64-linux-gnu/libstdc++.so.6 (0x00007fae79b05000)
	librt.so.1 => /lib/x86_64-linux-gnu/librt.so.1 (0x00007fae798fd000)
i7 5820K, 32 GB RAM, NVIDIA Geforce GTX 1080 + GTX 780, Windows 10 64bit, Blender 2.79b
Support LuxCoreRender project with salts and bounties

neo2068
Developer
Posts: 86
Joined: Tue Dec 05, 2017 6:06 pm

Re: Compiling on Linux

Post by neo2068 » Sun Jun 10, 2018 2:45 pm

It definitely has something to do with blender. The following code run fine with

Code: Select all

python3 testcode.py
and crashes inside blender on the last line with std::bad_cast.
On my system python 3.5.2 is installed and blender is compiled with python 3.5.3. Can that be a problem?

Code: Select all

from BlendLuxCore.bin import pyluxcore

camera_props = pyluxcore.Properties()
config_props = pyluxcore.Properties()

camera_props.SetFromString(
"""scene.camera.lookat.orig = 7.4811315536499023 -6.5076398849487305 5.3436651229858398
scene.camera.lookat.target = 6.8295731544494629 -5.8934693336486816 4.8983936309814453
scene.camera.up = -0.32401347160339355 0.30542084574699402 0.89539563655853271
scene.camera.type = perspective
scene.camera.screenwindow = -1 1 -0.5625 0.5625
scene.camera.clippingplane.enable = 0
scene.camera.fieldofview = 49.134342077604479
scene.camera.autovolume.enable = 1"""
)

config_props.SetFromString(
"""rtpathcpu.zoomphase.size = 4
rtpathcpu.zoomphase.weight = 0
path.pathdepth.total = 7
path.pathdepth.diffuse = 5
path.pathdepth.glossy = 5
path.pathdepth.specular = 6
renderengine.type = "RTPATHCPU"
lightstrategy.type = "LOG_POWER"
film.filter.width = 1.5
film.height = 600
scene.epsilon.min = 9.9999997473787516e-06
sampler.type = "RTPATHCPUSAMPLER"
film.width = 881
scene.epsilon.max = 0.10000000149011612
film.filter.type = "BLACKMANHARRIS"
path.forceblackbackground.enable = 0
renderengine.seed = 1
film.outputs.0.type = "RGB_IMAGEPIPELINE"
film.outputs.0.index = 0
film.outputs.0.filename = "RGB_IMAGEPIPELINE_0.png"
film.imagepipelines.0.0.type = "NOP"
film.imagepipelines.0.1.type = "TONEMAP_AUTOLINEAR"
film.imagepipelines.0.2.type = "TONEMAP_LINEAR"
film.imagepipelines.0.2.scale = 0.5
film.imagepipelines.0.radiancescales.0.enabled = 1
film.imagepipelines.0.radiancescales.0.globalscale = 1
film.imagepipelines.0.radiancescales.0.rgbscale = 1 1 1
batch.haltthreshold.stoprendering.enable = 0
batch.haltthreshold = 0.0001
batch.haltspp = 0
batch.halttime = 0"""
)

lux_scene = pyluxcore.Scene()
lux_scene.Parse(camera_props)

print(config_props)
print(camera_props)

render_config = pyluxcore.RenderConfig(config_props, lux_scene)
i7 5820K, 32 GB RAM, NVIDIA Geforce GTX 1080 + GTX 780, Windows 10 64bit, Blender 2.79b
Support LuxCoreRender project with salts and bounties

User avatar
B.Y.O.B.
Developer
Posts: 1728
Joined: Mon Dec 04, 2017 10:08 pm
Location: Germany
Contact:

Re: Compiling on Linux

Post by B.Y.O.B. » Sun Jun 10, 2018 2:53 pm

Try to run this in bash, then start Blender from the same bash session:

Code: Select all

export LC_ALL=en_US.UTF-8
Support LuxCoreRender project with salts and bounties

neo2068
Developer
Posts: 86
Joined: Tue Dec 05, 2017 6:06 pm

Re: Compiling on Linux

Post by neo2068 » Sun Jun 10, 2018 3:01 pm

B.Y.O.B. wrote:
Sun Jun 10, 2018 2:53 pm
Try to run this in bash, then start Blender from the same bash session:

Code: Select all

export LC_ALL=en_US.UTF-8
It gives the same error as before in blender.
i7 5820K, 32 GB RAM, NVIDIA Geforce GTX 1080 + GTX 780, Windows 10 64bit, Blender 2.79b
Support LuxCoreRender project with salts and bounties

User avatar
B.Y.O.B.
Developer
Posts: 1728
Joined: Mon Dec 04, 2017 10:08 pm
Location: Germany
Contact:

Re: Compiling on Linux

Post by B.Y.O.B. » Sun Jun 10, 2018 3:49 pm

You could try to pinpoint the problem to the exact line where it fails, e.g. with gdb.

Code: Select all

gdb ./programs/blender-2.79b-linux-glibc219-x86_64/blender
(gdb) run
(gdb) backtrace
(You can also use the graphical frontent for gdb, nemiver: https://en.wikipedia.org/wiki/Nemiver)

Code: Select all

sudo apt-get install nemiver
Support LuxCoreRender project with salts and bounties

User avatar
Dade
Developer
Posts: 1458
Joined: Mon Dec 04, 2017 8:36 pm

Re: Compiling on Linux

Post by Dade » Sun Jun 10, 2018 4:05 pm

It is likely to be one of standard C++ string function failing to parse a floating point number ("," Vs. "." separator).
Support LuxCoreRender project with salts and bounties

neo2068
Developer
Posts: 86
Joined: Tue Dec 05, 2017 6:06 pm

Re: Compiling on Linux

Post by neo2068 » Tue Jun 12, 2018 6:53 pm

B.Y.O.B. wrote:
Sun Jun 10, 2018 3:49 pm
You could try to pinpoint the problem to the exact line where it fails, e.g. with gdb.

Code: Select all

gdb ./programs/blender-2.79b-linux-glibc219-x86_64/blender
(gdb) run
(gdb) backtrace
(You can also use the graphical frontent for gdb, nemiver: https://en.wikipedia.org/wiki/Nemiver)

Code: Select all

sudo apt-get install nemiver
gdb doesn't bring any information because blender didn't crash, just throws the error. After (gdb) run I can't type in backtrace because blender is running.
i7 5820K, 32 GB RAM, NVIDIA Geforce GTX 1080 + GTX 780, Windows 10 64bit, Blender 2.79b
Support LuxCoreRender project with salts and bounties

Post Reply