Jump to content

Unerase ?

Recommended Posts

I understand that the eraser tool sets a layer's alpha to zero. Is the image information discarded at this point, or is there a way to unerase? Some sort of "paint on alpha" tool would be cool. Sorry if this has already been discussed. I tried to search, really :-)

Link to comment
Share on other sites

No sorry, this isn't possible with our toolset. While it's true that the eraser simply works on the alpha channel, we don't have a tool for setting the alpha channel to 255.

Although a CodeLab script to do this is trivial:

void Render(Surface dst, Surface src, Rectangle rect)
   for(int y = rect.Top; y     {
       for (int x = rect.Left; x         {
           ColorBgra c = src[x, y];
           c.A = 255;
           dst[x, y] = c;

I drew some red brush strokes, erased it all with the Eraser tool, and then this script "restored" the stuff I'd just "hidden."

The Paint.NET Blog: https://blog.getpaint.net/

Donations are always appreciated! https://www.getpaint.net/donate.html


Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...