In this two-part tutorial you’ll learn how to use Shadertoy shaders in GameMaker.
In part one we have adapted a godray shader to simulate light falling through the ocean surface.
In this second part we’ll apply a wave distortion effect to the application surface.
Part 1: https://youtu.be/gBnpBQCvzyI
The finished project file: https://www.dropbox.com/s/q7cn04b5zoz8guo/underwater_effect.gmz?dl=0
GameMaker Tutorial Box
Source
God Video!!
Good tutorial, thank you. But if you switch your game to fullscreen, the view with the shader is fixed to the left side of the screen. How can I fix this to be centralized in the middle of the screen?
Hi, hi! Totally new to shaders. Following along with your tutorial, and I got this on the compile, where yours works.
Error : [F]Shader_shaderTesting(37) : '' : syntax error
I can't work out what this means. Obviously I've done something wrong, but being that this is the first time I've ever touched a shader I'm not seeing what.
Google hasn't been helpful, mostly 'cause I'm not sure where I need to look or what it is I should google. Can you or someone else give me a hint?
Super cool tutorial! That fish game looks so fun! Could be a top app in the app store!!!
Can you make a tutorial on crt shaders in gamemaker?
thank you. i've been trying to find out how to do this for a long time.
Nice video. This is so useful.
I have a question, how do I make the background all distorted but the objects not.
U got a great voice, nice vid
I see you haven't posted any new videos lately, but I thought I should chime in and say this tutorial is a godsend for people starting out on shaders! Thank you for spending some time on creating it and I hope to see more on this subject in the future, there's not enough shader tutorials around!
any way to make this only apply to one object?, like an object called obj_water
any knows the name of this awesome dude?
Thanks for this tutorial I just recommended it to a customer who was asking about underwater effect. Perhaps you could share a link to where you got the background assets from.
Hi, how would you be able to apply this effect to a sprite rather than a surface?
(What I'm doing is replacing
texture_set_stage(u_texture_water, surface_get_texture(application_surface));
with
texture_set_stage(u_texture_water, sprite_get_texture(spr_character,0));
)
But it just glitches the screen.
How can I change the DistMax variables in real time? I tried doing the same thing as with iTime and iResolution but nothing happens, I expect because they're declared using '#define' instead of 'uniform float'?