Delphi Graphics32 - edit layer, erase parts of TBitmap32 (layer)

雨燕双飞 提交于 2019-12-24 04:49:10

问题


Is it possible to edit a layer's image? I mean, having a TImgView with multiple selectable layers, I would like to know if it is possible to select one layer (rubber-band and all), and for example click a button in the menu, and the mouse would turn into a rubber eraser that can delete contents under the mouse, on click. Just like the eraser in Paint.net or Photoshop.

Is it possible to achieve this? And if so, then how? I could not find a way of doing that so far. In regular TImage (TPaintBox) the solution would be to draw with white on top of the background, but that is not a solution when working with transparent layers/images. So what to do?

Any help (code) would be appreciated.

Thank you

来源:https://stackoverflow.com/questions/28279408/delphi-graphics32-edit-layer-erase-parts-of-tbitmap32-layer

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!