» cn.Tutorial Effects - Mr. Wiggle
This site relies heavily on Javascript. You should enable it if you want the full experience. Learn more.

cn.Tutorial Effects - Mr. Wiggle

English | Italian | Spanish | Japanese

TOC: Of Effects and Shaders
Back: Vertexshader Preparations
Next: Function Printing



vs2ps VS(
    float4 PosO  : POSITION,
    float4 TexCd : TEXCOORD0)

这里我们的兴趣点转移到 PosO向量,它是当前顶点的位置。我们要根据它的垂直位置(y坐标)来决定x坐标的偏移:

PosO.x += sin(PosO.y);


PosO.x += sin(PosO.y * Frequency + Phase) * Amplitude;


float Frequency = 10;
float Phase = 0;
float Amplitude = 0.01;
vs2ps VS(
    float4 PosO  : POSITION,
    float4 TexCd : TEXCOORD0)
    //declare output struct
    vs2ps Out;
    //offset x coordinate
    PosO.x += sin(PosO.y * Frequency + Phase) * Amplitude;
    //transform position
    Out.Pos = mul(PosO, tWVP);
    //transform texturecoordinates
    Out.TexCd = mul(TexCd, tTex);
    return Out;


mr wiggle patch

Next: Function Printing
Back: Vertexshader Preparations
TOC: Of Effects and Shaders

anonymous user login


~11h ago

auralscapes: By the way, if anyone would like to use any of my tracks or even parts thereof you are welcome. No fee. jerome@auralscapes.com

~12h ago

auralscapes: Thx for the advice. Much appreciated.

~14h ago

tonfilm: @auralscapes you can contact the author @dottore and ask him for the conditions.

~18h ago

auralscapes: A question for the group. I came across an application called Partitura. Is this app commercially available?

~1d ago

auralscapes: Don't have a clue how this all works but it is going to be an interesting journey indeed.

~4d ago

tonfilm: @all #vl now also has pin groups! vl-input-and-output-pin-groups #vvvv #creativecoding #visualprogramming #dotnet

~5d ago

evvvvil: Hey, broski, check my shader "The gamma ray feast" it goes bang and is commented with bad to mediocre jokes. https://www.shadertoy.com/view/wssXWl

~7d ago

hrovac: someone at b-seite on saturday?

~8d ago

woei: public player-(dx11.texture) performance and stability upgrade sponsored by https://meso.design/