zero01101 / openOutpaint

local offline javascript and html canvas outpainting gizmo for stable diffusion webUI API 🐠
MIT License
507 stars 44 forks source link

layer-based background removal #107

Closed zero01101 closed 1 year ago

zero01101 commented 1 year ago

Is your feature request related to a problem? Please describe. it is absolutely not

Describe the solution you'd like so like when i was talking about difference globalcompositeoperation and failing at it in photoshop, i've since discovered what i meant was "background subtraction" and i still kinda think that'd be a nifty feature, like c'mon

no actually describe it dummy
oh uh so like if an in/outpaint dream or maybe even txt2img is requested with the "subtract background" option ticked, the following should occur:

Describe alternatives you've considered well i guess painstakingly erasing identical pixels would work if i wasn't impatient?

Additional context i will 100% try and almost certainly fail to implement something like this myself, but uh, ahem don't let that stop anyone else from showing me who's boss ;)

priority literally the lowest possible; like if there's an errant apostrophe in a readme 2 versions ago that's probably more important

seijihariki commented 1 year ago

I'll leave this one to you, then!

zero01101 commented 1 year ago

i didn't forget about this i swear

https://github.com/zero01101/openOutpaint/commit/02bf04c25734ae4156b637eda0b1cd5cc6a3d568

it... kinda works? not great with img2img and very bad with sketch tool lmao

bgremove.webm

zero01101 commented 1 year ago

https://github.com/zero01101/openOutpaint/wiki/Manual#dream and scroll down a bit? janky but exists now