Jump to content

RemoveBG Integration Effect


WhelanB
 Share

Recommended Posts

This plugin enables you to interface with remove.bg to remove backgrounds from your images directly inside Paint.NET 

A remove.bg account and API key is required to use this plugin - you receive 50 free previews a month on RemoveBG which will let you use this plugin, but you will see a slight drop in image quality using the free previews. The plugin will consume paid credits first if you have any credited against your account. In the next update I plan to add additional header options in settings to account for this.

 

 

Your API key will be stored in config.json, next to the dll

 

This plugin is compatible with Paint.NET 4

 

Download: https://github.com/WhelanB/PDN-RemoveBG/releases

 

 

Effects->Tools->Remove Background

Executing the Effect

 

 

Edited by WhelanB
config
  • Like 1
  • Upvote 1
Link to comment
Share on other sites

@WhelanB, if you're going to package a shared DLL like NewtonsoftJson.dll, then you need to make sure your plugin:

  1. Targets PDN 4.3 and .NET 5
  2. It must be installed to its own folder within Effects
  3. It should have a .deps.json file, which should automatically be created by Visual Studio when you build the project

Alternately, you can use something like ILMerge (IIRC) to merge everything into 1 DLL.

 

Otherwise there can be conflicts with other plugins that might want to use other versions of NewtonsoftJson.dll, or with the one that PDN uses.

 

This is a new requirement for plugins because it just became possible to do this sort of isolation starting with PDN 4.3. I've removed your download link so that you can provide a new version that satisfies these requirements.

 

(Also, let me be clear, this isn't because you "broke" a rule, and you're not being "punished" -- I should've published this rule/guidance a week or so ago with the release of PDN 4.3. I've added the rule to https://forums.getpaint.net/topic/13129-rules-for-plugins-that-are-published-on-this-forum/. Yours was just the first plugin I saw which needed this applied to it.)

 

  • Thanks 1

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

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

forumSig_bmwE60.jpg

Link to comment
Share on other sites

@WhelanB, when you switch to .NET 5, using NewtonsoftJson might not be necessary anymore (depending on the APIs you're using).

The new System.Text.Json namespace has many replacement/alternative APIs; with a lot more coming in .NET 6.

Hopefully, that will remove the need for external dependency DLLs on your Effect.

  • Like 2
Link to comment
Share on other sites

  • 2 weeks later...

@NSD the fixed version is up on the GitHub page for the plugin https://github.com/WhelanB/PDN-RemoveBG/releases

 

I'll modify the post the include a link to that page

  • Thanks 1
  • Upvote 1

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

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

forumSig_bmwE60.jpg

Link to comment
Share on other sites

This plugin  is not not free to use 👎, see -> https://www.remove.bg/pricing

On 10/7/2021 at 4:23 PM, WhelanB said:

(you receive 50 free credits on account creation)

☝️That's only half the truth.

Quote

As a remove.bg user you get 1 free credit for signing up, and 50 free API calls for preview images each month. Since remove.bg for Windows/Mac/Linux utilizes the API that means you can process 50 preview images (up to 0.25 megapixels, e.g. 625x400) with it for free each month.

 

Edited by Rle

sig_2dsc_0836m1jap.png

Link to comment
Share on other sites

On 10/19/2021 at 12:10 AM, Rle said:

This plugin  is not not free to use 👎, see -> https://www.remove.bg/pricing

☝️That's only half the truth.

 

I've updated the main post to call them "Free Previews via API" instead of "Free Credits" since that's what remove.bg refers to them as - I had these in my head as "free credits" rather than a "free" paid credit if that makes sense - the plugin will resize your images back to their original size, so you'll see a slight loss of quality using these previews.

 

I'm not affiliated in any way with remove.bg, I wrote this for my own personal use as a PDN user and figured others might find it useful!

Edited by WhelanB
  • Like 1
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.

Guest
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.

 Share

×
×
  • Create New...