» Image Adjustment Pack
This site relies heavily on Javascript. You should enable it if you want the full experience. Learn more.

Image Adjustment Pack

effect

about

pixelshader functions resource

v1 includes:

  • Invert
  • Contrast
  • Saturation: Greyscale & Saturation
  • Levels
  • Tonecurves
  • LumaMatte: Luma & Inverse Luma
  • ColorMatte

maybe a bunch of single effects, which are combining differnt functions can be avoided this way...

feedback and tell me whats missing, plz

download

ImageAdjustmentPack_v1.zip
28.01.11 [16:17 UTC] by woei | 2170 downloads

West 28/01/2011 - 20:22

Nice collection to "chrush some blacks" :)

And big thumbs up for the Mattes!!

lasal 29/01/2011 - 21:23

very usefull ;)

woei 31/01/2011 - 20:54

thx for the flowers, guys!

any suggestions, what's missing for the basics? or other feedback?

West 02/02/2011 - 00:49

Spreadable key-colors would be funny. what is a .FXH vs a .FX ??

And the Hue/Saturation filter, with colorize function, like in Photoshop is something I could use.

woei 02/02/2011 - 01:36

actually you can do the spreading of keycolors yourself. thats why its a FXH.

there simple functions wrapped in these fxh files. so if you for example need a shader to control saturation, contrast and then keying out the green, you don't need to copy paste everything together but just include the .fxh and call the functions like:

#include "path/Saturation.fxh"
#include "path/Contrast.fxh"
#include "path/ColorMatte.fxh"

and in the pixelshader

float4 col=tex2d(Samp,In.TexCd)
col = Saturation(col); 
col = Contrast(col);
col.a=ColorMatte(col);
return col;

hope is, that this could prevent a lot of similar shaders (f)lying around

phlegma 18/04/2011 - 13:06

Create Work, Create Help, Thanx

deby 07/06/2011 - 18:53

Create contibution. Thanks!
I try to create an allinOne FX but with no result...

An idea?
Thanks a lot

//@author: woei
//@help: greyscale conversion function and saturation adjustment per channel
//@tags: greyscale, saturation, color correction, image adjustment, pixelshader
 
// --------------------------------------------------------------------------------------------------
// PARAMETERS:
// --------------------------------------------------------------------------------------------------
 
//transforms
float4x4 tW: WORLD;        //the models world matrix
float4x4 tV: VIEW;         //view matrix as set via Renderer (EX9)
float4x4 tP: PROJECTION;
float4x4 tWVP: WORLDVIEWPROJECTION;
 
//texture
texture Tex <string uiname="Texture";>;
sampler Samp = sampler_state    //sampler for doing the texture-lookup
{
    Texture   = (Tex);          //apply a texture to the sampler
    MipFilter = Linear;         //sampler states
    MinFilter = Linear;
    MagFilter = Linear;
};
 
//texture transformation marked with semantic TEXTUREMATRIX to achieve symmetric transformations
float4x4 tTex: TEXTUREMATRIX <string uiname="Texture Transform";>;
 
#include "Contrast.fxh"
#include "Invert.fxh"
#include "Levels.fxh"
#include "Saturation.fxh"
#include "Tonecurve.fxh"
 
//the data structure: "vertexshader to pixelshader"
//used as output data with the VS function
//and as input data with the PS function
struct vs2ps
{
    float4 Pos  : POSITION;
    float2 TexCd : TEXCOORD0;
};
 
// --------------------------------------------------------------------------------------------------
// VERTEXSHADERS
// --------------------------------------------------------------------------------------------------
vs2ps VS(
    float4 PosO  : POSITION,
    float4 TexCd : TEXCOORD0)
{
    //declare output struct
    vs2ps Out;
 
    //transform position
    Out.Pos = mul(PosO, tWVP);
 
    //transform texturecoordinates
    Out.TexCd = mul(TexCd, tTex);
 
    return Out;
}
 
// --------------------------------------------------------------------------------------------------
// PIXELSHADERS:
// --------------------------------------------------------------------------------------------------
float4 PS(vs2ps In): COLOR
{
    float4 col = tex2d(Samp, In.TexCd);
    col = Contrast(col);
    col = Invert(col);
    col = Levels(col);
    col = Saturation(col);
    col = Tonecurve(col);
    return col;
}
 
// --------------------------------------------------------------------------------------------------
// TECHNIQUES:
// --------------------------------------------------------------------------------------------------
 
technique TFX
{
    pass P0
    {
        VertexShader = compile vs_1_1 VS();
        PixelShader  = compile ps_1_0 GREY();
    }
}
 
technique TFixedFunction
{
    pass P0
    {
        //transforms
        WorldTransform[0]   = (tW);
        ViewTransform       = (tV);
        ProjectionTransform = (tP);
 
        //texturing
        Sampler[0] = (Samp);
        TextureTransform[0] = (tTex);
        TexCoordIndex[0] = 0;
        TextureTransformFlags[0] = COUNT2;
        //Wrap0 = U;  // useful when mesh is round like a sphere
 
        Lighting       = FALSE;
 
        //shaders
        VertexShader = NULL;
        PixelShader  = NULL;
    }
}
woei 10/06/2011 - 16:46

@deby: whats the error in the editor?
are the fxh files positioned beside the fx you are editing?
and you probably have to switch to shader model 2.0 at least. (technique -> pass p0 -> PixelShader...)

deby 10/06/2011 - 21:55

Hello woei,
the error appears here:

float4 PS(vs2ps In): COLOR
{

    float4 col = tex2d(Samp, In.TexCd);

col = Contrast(col);
col = Invert(col);
col = Levels(col);
col = Saturation(col);
col = Tonecurve(col);
return col;
}
the fxh files are in the same directory as the pixelshader.
I am totally beginner in programming pixelshader...

woei 14/06/2011 - 16:25

@deby: which line exactly does the error appear? and did you set the shader model in the technique to 2.0 or 3.0?

krementsov 29/05/2015 - 20:44

Hello woei,
Can you help me?
All nodes in this pack don't work with DX11, but work with DX9. What could be the problem?

Pin "Technique" is red

I can give you additional if you need.

Or may be you know another good pack for working with image.

blausand 29/05/2015 - 20:57

@deby: Why is your pixelshader called PS() but your pass calls GREY()?

anonymous user login

Shoutbox

~4d ago

~7d ago

joreg: The Winter Season of vvvv workshops is now over but all recordings are still available for purchase: https://thenodeinstitute.org/ws23-vvvv-intermediates/

~14d ago

schlonzo: Love the new drag and drop functionality for links in latest previews!

~22d ago

joreg: Workshop on 29 02: Create Sequencers and Precise Clock Based Tools. Signup here: https://thenodeinstitute.org/courses/ws23-vvvv-08-create-sequencers-and-precise-clock-based-tools-in-vvvv-gamma/

~29d ago

joreg: Workshop on 22 02: Unlocking Shader Artistry: A Journey through ‘The Book of Shaders’ with FUSE. Signup here: https://thenodeinstitute.org/courses/ws23-vvvv-12-book-of-shaders/

~1mth ago

joreg: Talk and Workshop on February 15 & 16 in Frankfurt: https://visualprogramming.net/blog/vvvv-at-node-code-frankfurt/

~1mth ago

woei: @Joanie_AntiVJ: think so, looks doable

~1mth ago

xd_nitro: Anyone remember who increased projector brightness by removing some components that product the color?

~1mth ago

Joanie_AntiVJ: This looks super interesting (vectors over network) would anyone here know how to implement this in beta? https://github.com/madmappersoftware/Ponk