Armory: Area light and spot light do not like each other

Created on 10 Mar 2019  路  6Comments  路  Source: armory3d/armory

ERROR: /home/trsh/forks/nb_files/test_lab/build_test_lab/compiled/Shaders/std/light.glsl:31: 'shadowMapPoint' : redeclaration of array with size
ERROR: /home/trsh/forks/nb_files/test_lab/build_test_lab/compiled/Shaders/deferred_light.frag.glsl:6: '#' : preprocessor directive cannot be preceded by another token

bug

All 6 comments

Could you upload a test file that has this issue with the version of Armory / Blender / your operating system?

I happen to have the same issue. If it's okay I will upload my files and errors. If that's not cool just delete my comment or let me know I will delete it and from now on will start my own bug thread.

By the way this error started happening after I deleted a model from the scene, everything worked last night, today I deleted a model after realizing it had wayyyy too many tris and moved some things around and went to run the player to no avail.

room_1.zip

Read prefs: C:\UsersBeastAppData\RoamingBlender FoundationBlender\2.80\confi
g\userpref.blend
AL lib: (EE) UpdateDeviceParams: Failed to set 48000hz, got 44100hz instead
found bundled python: C:\UsersBeast\DownloadsArmory_06_win64Armory\2.80\pytho
n
Armory: Proxy objects synchronized
Read blend: C:\UsersBeast\Desktop\room_1.blend

Armory v0.6 ($Id: 988482e02afefe458b00e4dea75db2d01b76e49d $)
OS: win, Target: html5, GAPI: webgl, Blender: 2.80 (sub 44)
Exporting Scene
Exporting mesh Cube.001
Exporting mesh Cube
Exporting mesh Cylinder.001
Exporting mesh Sphere
Exporting mesh Sphere.001
Exporting mesh Cylinder.013
Exporting mesh Cube.008
Exporting mesh Cylinder.014
Exporting mesh Cube.005
Exporting mesh Cube.010
Exporting mesh Cube.012
Exporting mesh Cube.013
Exporting mesh Cube.014
Exporting mesh Cube.015
Exporting mesh Cube.016
Exporting mesh Cube.017
Exporting mesh Cube.019
Exporting mesh Cube.004
Exporting mesh Cube.002
Scene exported in 6.877393484115601
Exported modules: ['audio', 'ui']
Shader flags: ['_Irr', '_EnvCol', '_Deferred', '_ShadowMap', '_CSM', '_LTC', '_S
pot', '_Clusters', '_SMAA', '_SSAO']
Khafile flags: ['arm_deferred', 'arm_csm', 'arm_ltc', 'arm_spot', 'arm_clusters'
, 'rp_hdr', 'rp_renderer=Deferred', 'rp_shadowmap', 'rp_shadowmap_cascade=1024',
'rp_shadowmap_cube=512', 'rp_background=World', 'rp_render_to_texture', 'rp_com
positornodes', 'rp_antialiasing=SMAA', 'rp_supersampling=1', 'rp_ssgi=SSAO', 'rp
_gi=Off']
Running: ['C:/Users/Beast/Downloads/Armory_06_win64/Armory/armsdk//nodejs/node.
exe', 'C:/Users/Beast/Downloads/Armory_06_win64/Armory/armsdk//Kha/make', 'html5
', '-g', 'webgl', '--shaderversion', '300', '--parallelAssetConversion', '4', '-
-to', 'build_room_1/debug']
Using project from C:\UsersBeast\Desktop
Using Kha from C:\UsersBeast\DownloadsArmory_06_win64Armory\armsdk\Kha
Creating Kha project.
Exporting asset 1 of 21 (Scene.arm).
Exporting asset 2 of 21 (World_irradiance.arm).
Exporting asset 3 of 21 (mesh_Cube.001.arm).
Exporting asset 4 of 21 (mesh_Cube.002.arm).
Exporting asset 5 of 21 (mesh_Cube.004.arm).
Exporting asset 6 of 21 (mesh_Cube.005.arm).
Exporting asset 7 of 21 (mesh_Cube.008.arm).
Exporting asset 8 of 21 (mesh_Cube.012.arm).
Exporting asset 9 of 21 (mesh_Cube.010.arm).
Exporting asset 10 of 21 (mesh_Cube.013.arm).
Exporting asset 11 of 21 (mesh_Cube.014.arm).
Exporting asset 12 of 21 (mesh_Cube.015.arm).
Exporting asset 13 of 21 (mesh_Cube.016.arm).
Exporting asset 14 of 21 (mesh_Cube.017.arm).
Exporting asset 15 of 21 (mesh_Cube.019.arm).
Exporting asset 16 of 21 (mesh_Cube.arm).
Exporting asset 17 of 21 (mesh_Cylinder.001.arm).
Exporting asset 18 of 21 (mesh_Cylinder.014.arm).
Exporting asset 19 of 21 (mesh_Cylinder.013.arm).
Exporting asset 20 of 21 (mesh_Sphere.001.arm).
Exporting asset 21 of 21 (mesh_Sphere.arm).
Exporting asset 1 of 8 (Material_002_data.arm).
Exporting asset 2 of 8 (Material_003_data.arm).
Exporting asset 3 of 8 (Material_004_data.arm).
Exporting asset 4 of 8 (Material_005_data.arm).
Exporting asset 5 of 8 (Material_data.arm).
Exporting asset 6 of 8 (None_data.arm).
Exporting asset 7 of 8 (armdefault_data.arm).
Exporting asset 8 of 8 (shader_datas.arm).
Exporting asset 1 of 1 (brdf.png).
Exporting asset 1 of 1 (smaa_area.png).
Exporting asset 1 of 1 (smaa_search.png).
Exporting asset 1 of 1 (font_default.ttf).
Compiling shader 1 of 25 (Material_002_mesh.frag.glsl).
Compiling shader 2 of 25 (Material_003_mesh.frag.glsl).
Compiling shader 3 of 25 (Material_004_mesh.frag.glsl).
Compiling shader 4 of 25 (Material_005_mesh.frag.glsl).
Compiling shader 5 of 25 (Material_mesh.frag.glsl).
Compiling shader 6 of 25 (None_mesh.frag.glsl).
Compiling shader 7 of 25 (armdefault_mesh.frag.glsl).
Compiling shader 8 of 25 (armdefault_mesh.vert.glsl).
Compiling shader 9 of 25 (armdefault_shadowmap.frag.glsl).
Compiling shader 10 of 25 (armdefault_shadowmap.vert.glsl).
Compiling shader 11 of 25 (blur_edge_pass.frag.glsl).
Compiling shader 12 of 25 (compositor_pass.frag.glsl).
Compiling shader 13 of 25 (compositor_pass.vert.glsl).
Compiling shader 14 of 25 (deferred_light.frag.glsl).
Compiling shader 15 of 25 (pass.vert.glsl).
Compiling shader 16 of 25 (pass_viewray.vert.glsl).
Compiling shader 17 of 25 (smaa_blend_weight.frag.glsl).
Compiling shader 18 of 25 (smaa_blend_weight.vert.glsl).
ERROR: C:\UsersBeast\Desktop\build_room_1\compiled\Shaders\std/light.glsl:56: '
shadowMapSpot' : redeclaration of array with size
ERROR: C:\UsersBeast\Desktop\build_room_1\compiled\Shaders\deferred_light.frag.
glsl:6: '#' : preprocessor directive cannot be preceded by another token
ERROR: 2 compilation errors. No code generated.

ERROR: Linking fragment stage: Missing entry point: Each stage requires one entr
y point

SPIR-V is not generated for failed compile or link

Compiling shader 14 of 25 (deferred_light.frag.glsl) failed:
Shader compiler error.
(node:5332) UnhandledPromiseRejectionWarning: Shader compiler error.
(node:5332) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This
error originated either by throwing inside of an async function without a catch
block, or by rejecting a promise which was not handled with .catch(). (rejection
id: 2)
(node:5332) [DEP0018] DeprecationWarning: Unhandled promise rejections are depre
cated. In the future, promise rejections that are not handled will terminate the
Node.js process with a non-zero exit code.
Finished in 7.708440780639648
Build failed, check console

OK, so using the room_1.blend file above from @TheButtholer I'm also getting the error:

ERROR: /tmp/build_room_1/compiled/Shaders/std/light.glsl:56: 'shadowMapSpot' : redeclaration of array with size 
ERROR: /tmp/build_room_1/compiled/Shaders/deferred_light.frag.glsl:6: '#' : preprocessor directive cannot be preceded by another token 
ERROR: 2 compilation errors.  No code generated.

Using:

  • Blender 2.8 beta
  • Armory 0.7 git ( f618d47c6cfb765b981cc21677d775fc25786df8 )
  • Kubuntu Linux 17.10 64 bit

What are you using, @trsh / @TheButtholer ?

Using:

  • Blender 2.80.44 beta
  • Armory v0.6 ( 988482e02afefe458b00e4dea75db2d01b76e49d )
  • Windows 7 64-bit

Ubuntu bionic, arm 0.6 from itch

Happen same here:

ERROR: C:\Users\name\Downloads\room_1\build_room_1\compiled\Shaders\std/light.glsl:56: 'shadowMapSpot' : redeclaration of array with size
ERROR: C:\Users\name\Downloads\room_1\build_room_1\compiled\Shaders\deferred_light.frag.glsl:6: '#' : preprocessor directive cannot be preceded by another token
ERROR: 2 compilation errors.  No code generated.


ERROR: Linking fragment stage: Missing entry point: Each stage requires one entry point

SPIR-V is not generated for failed compile or link

Compiling shader 18 of 25 (smaa_blend_weight.vert.glsl).
Compiling shader 14 of 25 (deferred_light.frag.glsl) failed:
Shader compiler error.
(node:8716) UnhandledPromiseRejectionWarning: Shader compiler error.
(node:8716) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 2)
(node:8716) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
Finished in 16.794061183929443
Build failed, check console

Tried deleting area light and it compile, but another bug (Objects are displaced)(need it own bug report):

allalal

OS: WIndows 10 Home
Version: Latest Armory from git

Edit: Area light and spot light doesn't like each other, if you delete area light then it will compile or if you delete spot light instead then it will compile, when spot light are deleted instead then object displacement bug doesn't happen

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Sanva picture Sanva  路  3Comments

AttSee picture AttSee  路  4Comments

luboslenco picture luboslenco  路  3Comments

Amir-Arsalan picture Amir-Arsalan  路  4Comments

e1e5en-gd picture e1e5en-gd  路  3Comments