   In directX 2D how I can change color in specific area?
  I want to change color for character. for example: from green to red.I think it may be the way that I can set the condition as if this is green then chang to be red. I tried about diffuse but it is about light....that's not what I want.In directX, there are some ways to make it?   
  Well you can use fill rect but you need to detect the pixels you want to change first.Another thing you can do is make a shader which will replace the colors you want and render the texture as a quad texture into a surface (which might be itself)   ;Quote:Original post by ShaneeWell you can use fill rect but you need to detect the pixels you want to change first.Another thing you can do is make a shader which will replace the colors you want and render the texture as a quad texture into a surface (which might be itself)I don't understand about fill rect thing, can you provide more detail?and about shadw, I heard that it is complicated....and when I looked on internet, I feel OHhhhhh can I do that !??If the thing that you mention is simple that I thought, please advice me   ;  Here are two functions which can help you look at the pixels in a texture and edit them:http://msdn.microsoft.com/en-us/library/bb205913(VS.85).aspxhttp://msdn.microsoft.com/en-us/library/bb174353(VS.85).aspxBut the shader way is probably faster, although yes, it can be more complicated.If you don't know shaders yet, it might be better to stay away from them for a little bit longer.Edit: Another idea is if your game is in 2D, to separate the area which you want to have its color changed in to another texture and have it white in there.Then render it above the texture which doesn't get changed but with a different D3DCOLOR value when calling the sprite component to draw. that way the white part will change its color to whatever color you specify. The background must be transparent.   ;  Are you using Direct2D or Direct3D? I'm a bit confused about this :)   