Jump to content

UV shifting on model texture ?


YouGroove
 Share

Recommended Posts

  • 1 month later...

Sorry I'm trying to get this working and I'm a shader noob which is a bad combo....

 

 


//Uniforms
uniform sampler2D texture0;//diffuse map
uniform float currenttime;

//Inputs
varying vec2 ex_texcoords0;
varying vec2 ex_texcoords1;
varying vec4 ex_color;
varying float ex_selectionstate;

void main(void)
{

vec2 texcoords = ex_texcoords0;

texcoords.y += currenttime/100.0;

vec4 outcolor = ex_color;

//Modulate blend with diffuse map
outcolor *= texture2D(texture0,ex_texcoords0);

//Blend with selection color if selected
gl_FragColor = outcolor;
}

 

Obviously it's not working, am I on the right track? Any clues on how to get it working? Any help would be appreciated!

 

Cheers!

trindieprod.png?dl=0spacer.png?dl=0steam-icon.png?dl=0twitter-icon.png?dl=0spacer.png?dl=0
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...