Open defektu opened 1 year ago
Displacement map vertex shader would be a cool feature to implement.
Managed to prepare a project with displacement effect by replacing transformVS.
Here is the Project Link (Working properly with lights and shadows)
Displacement Effect in use:
if(options.useDisplacement) code+= #define DISPLACEMENT
#ifdef DISPLACEMENT
matrix_normal * sample_texture
code += displacementVS
Hey ... that's pretty exciting. Feel free to create a PR and we can discuss it there perhaps?
Created a draft pull request #5573
Displacement map vertex shader would be a cool feature to implement.
Managed to prepare a project with displacement effect by replacing transformVS.
Here is the Project Link (Working properly with lights and shadows)
Screenshots
Displacement Effect in use:
My try on trying to create it in engine: (can provide a PR but it is not working as intended)
if(options.useDisplacement) code+= #define DISPLACEMENT
in shader definition.#ifdef DISPLACEMENT
seems not picking while rendering shadows.Screenshots
Issues while engine implementation :
matrix_normal * sample_texture
will throw error otherwise because of undefined texture)code += displacementVS
.Recommendations: