|
do SMARTSHADERs know what pixel they are altering?
Hey!
Im just getting my feet wet into writing SMARTSHADERs. Your tutorial page has been a huge help so far.
I see that you can get the height and width of the current window, and also that conditionals are supported. I understand that the shader program will run for every pixel to be displayed. Can the SMARTSHADER program get the information as to what pixel it is currently altering?
What i wanted to setup was different effects being seperated on the screen at the same time. Something along the lines of:
if (currentPixel < width / 2)
doEffect1;
else
doEffect2;
in essance there'd be a vertical line seperating the 2 effects on the screen. effect1 on the left and effect2 on the right.
So is there some command that will return this info rather than my fictional currentPixel? Thanks!
|