cloudinary-community / cloudinary-util

https://cloudinary-util.vercel.app
MIT License
12 stars 19 forks source link

Extract #190

Closed colbyfayock closed 3 months ago

colbyfayock commented 3 months ago

Description

Adds Extract feature that allows you to "extract" or remove the background from around an object by using a prompt.

https://cloudinary.com/documentation/transformation_reference#e_extract

Syntax:

// String
extract="space jellyfish"

// Array of strings
extract={{
  prompt: ['space jellyfish', 'octocat'],
}}

// Object
extract={{
  prompt: 'space jellyfish',
  multiple: true,
  mode: 'mask', 
  invert: true
}}

// Object with prompt array
extract={{
  prompt: ['space jellyfish', 'octocat'],
  mode: 'mask', 
}}

Issue Ticket Number

Fixes #168

Type of change

Checklist

github-actions[bot] commented 3 months ago

:tada: This PR is included in version @cloudinary-util/url-loader-v5.9.0 :tada:

The release is available on:

Your semantic-release bot :package::rocket: