hello, would anyone be willing to walk me through how to setup global effects, for example blur or pixelation
i cant seem to get my head around it from reading and the examples
it may not be possible, but this is one i was trying to use:
ive tried to implement the pixelation shader, but im not sure that ive got it working properly...i attached it
could i ask you a question? is there a way i could set up a gaussian blur effect that is applied on a per model basis? so that i could relate it to a defined "identity" variable in spawnmodel instances
then i could, in a way, simulate focusing on objects
The standard way of doing that is using a depth-map, but I guess you could calculate the depth on a per-object base ( instead of per-pixel ) as well if you want. In any case, you need to render the depth data you want to use to a texture, so you can sample that data to control the gaussian amount in your shader.
K
Last edited by Kjell on Mon Nov 07, 2011 1:05 pm, edited 1 time in total.
would you show me how to do this? or do you have a zgeproj i could look at? any help is great hehe
edit: i just tried your pixelation shader code and the result is similar to the other one, as in there are lines that trace outward in a grid. im very much a newbie still, so iwasnt sure if it was correct to see this.
thanks i will still make use of this.
pond wrote:i just tried your pixelation shader code and the result is similar to the other one
Are you sure it compiled correctly ( and added + set the required variables ), otherwise it won't actually update the shader. Attached are what both shaders look like for me.
hey kjell, you are right - i had set values for screen_cx and screen_cy, but i was only looking at it in the design window. once i build the exe it looks fine
thanks.