#Hello!

1 messages · Page 1 of 1 (latest)

willow prism
#

After upgrading to bevy 0.11 everything is working fine. The only problem I have is with shaders. I am getting the errors

in terrain.wgsl:
34 │ out.world_position = mesh_position_local_to_world(mesh.model, vec4<f32>(vertex.position, 1.0)); │ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ unknown identifier │ = no definition in scope for identifier: 'mesh_position_local_to_world'

here I have imported in the top #import bevy_pbr::mesh_functions mesh_position_local_to_world, mesh_position_world_to_clip, mesh_normal_local_to_world

and

in water.wgsl
14 │ let t = globals.time % scroll_time; │ ^^^^^^^ unknown identifier │ = no definition in scope for identifier: 'globals'

here I have imported in the top #import bevy_sprite::mesh_view_bindings globals

Am I missing something?

Thank you for your help!

quartz ocean
#

i need be define and find in bevy's wsgl

#

it need

#
#import bevy_pbr::mesh_functions as mfn
mfn::mesh_position_local_to_world(...
#

just like that

#

#import bevy_sprite::mesh_view_bindings globals maybe #import bevy_sprite::mesh_view_bindings as mvb and use mvb::globals

willow prism
#

Thank you for suggestions. Was not wrong but overall not the solution for my problem - but it helped to find it. My problem was more "clone project cleanly into clean notebook and for get things". I have written a custom asset loader which is using a path which I am providing over an env variable. My target path had old shader files. When I have changed towards your suggestion I noticed that the changes were not applied. Thus, old shader files were not compatible for 0.11.

The problem is resolved. Thank you very much!