Jump to content

uv_transform for emission


photo

Recommended Posts

quoting a question I've asked elsewhere but got no answers.

let's say I want to add a parameter to the mesh_base.basemat  to control uv  texture tiling for the emission state (using same UVset as diffuse ) like how this is already implemented for ao_map (ie: do a scale or animation on UV coords but just for the emission map ). 

Do I only need to add this in the basemat (and will it work) or is it to do with vertex/fragment shader instead  (or both)?

So I've created my own basemat and added what seems to be all the mechanic (based on something similar to the ao_map OR the lightmap which by the case already has a uv_transfrom parameter) in the xml, I get my new  parameter uv transforrm_emission showing in the gui when I change the emission state but when I change the vec4 values nothing happens, I guess nothing is passed to the shader or forgot something in the mat xml?

any advice ?

 

Edited by romain.janil
adding details
Link to comment

Hi, I guess that if you need a custom UV transform you will need to update both shader and material files. If you want to use same UV transform as for albedo, you will only need to modify shader file to transform input UV.

In any case you will have to modify core/shaders/mesh/emission/emission.shader file at line 133 (in 2.7.2.1 sdk) 

Hope this helps a bit. Javier

Link to comment

HI Javier,

thanks for your help, that's what I thought too, that makes sense.

However, maybe it's to do with using the eval_kit here I don't see any .shader file... in fact the path /shaders/... doesn't exist...

hum...

Link to comment
×
×
  • Create New...