HiveBrain v1.2.0
Get Started
← Back to all entries
snippetbashTip

pbmmask — Create a mask bitmap from a regular bitmap. See also: `pambackground`. More information: <https://ne

Submitted by: @import:tldr-pages··
0
Viewed 0 times
createcommandregularmaskfrompbmmaskclibitmap

Problem

How to use the pbmmask command: Create a mask bitmap from a regular bitmap. See also: pambackground. More information: <https://netpbm.sourceforge.net/doc/pbmmask.html>.

Solution

pbmmask — Create a mask bitmap from a regular bitmap. See also: pambackground. More information: <https://netpbm.sourceforge.net/doc/pbmmask.html>.

Create a mask bitmap separating background from foreground:
pbmmask {{path/to/image.pbm}} > {{path/to/output.pbm}}


Expand the generated mask by one pixel:
pbmmask {{[-r|-expand]}} {{path/to/image.pbm}} > {{path/to/output.pbm}}

Code Snippets

Create a mask bitmap separating background from foreground

pbmmask {{path/to/image.pbm}} > {{path/to/output.pbm}}

Expand the generated mask by one pixel

pbmmask {{[-r|-expand]}} {{path/to/image.pbm}} > {{path/to/output.pbm}}

Context

tldr-pages: common/pbmmask

Revisions (0)

No revisions yet.