2008/05/18

The Labs.Com PicArt PicArt: Programs
Last update 2001/07/16
The Labs - Design & Functionality For The Net

All Programs of the PicArt Package

  1. Input Images Formats
  2. Output Image Format
  3. Programs
  4. Resources
PicArt: Programs
1. Input Images Formats
As input following formats are supported:
  • PNM (Raw): PPM (RGB), PGM (Grey), PBM (bitmap)
  • GIF (no support of transparency)
  • XPM (support of transperancy)
  • JPEG (color and grey)
All programs write the resulting images (with few exceptions) direct to stdout.

PicArt: Programs
2. Output Image Format

PicArt uses PPM (P6) format. Following formats are created & handled by PicArt programs:

RGB 24bits
RGB 24bitsAlpha 8bit
RGB 24bitsAlpha 8bitZ-buffer 32bits

The alpha channel (8bits per pixel) is appended behind the regular PPM file and doesn't affect XV or any PBMPLUS or NETPBM program. Note: PBMPLUS or NETPBM programs will dump the alpha-channel when passed to them. paalpha or alpha you can use to create an alpha-channel, patext or show creates a text-image with an alpha-channel by default.

The possible Z-Buffer, in case you use padraw3d standalone program or draw3d, is appened behind alpha-channel (if none existed an alpha-channel will created).

Consideration about file-size: a 640x400 picture RGB with Alpha requires 1MB diskspace, a 1280x1024 RGBA uses 5.2MB

PicArt: Programs
3. Programs

papaste
 % papaste <baseimage> <x> <y> [-mode <modes>] <pasteimage>
<x> <y> are absolute coords by default ie (5 5)
ie. 5- 10- -would be 5 pixels from right, 10 pixels from bottom
center 10 -would be x-position centered
or even .5x or .3x for relative positioning
modes: copy (default), darken, lighten, multiply

paalpha
 % paalpha <baseimage> [<alphaimage>|-transp<r>,<g>,<b>]

paextract
 % paextract <baseimage> <which>
which can be 'rgba'

patile
 % patile <tileimage> <w> <h>

pashade
 % pashade <baseimage> <shadeimage>

pashear
 % pashear <baseimage> <x>

pasmooth
 % pasmooth <baseimage> <depth>

paborder
 % paborder <baseimage> <w> <h> [-col <r> <g> <b> <a>]

pagamma
 % pagamma <baseimage> <r> <g> <b> <a>

pabutton
 % pabutton <w> <h> <border> <r> <g> <b>

pamask
 % pamask <baseimg> <materialimg> [-fit] [-orig]

pablowup
 % pablowup <baseimage> <factor>

pawavy
 % pawavy <baseimage> <scale> <heavyness> [-noise <xscale> <yscale>] [-circular <xr> <yr>] [-linear <rot>]

pabumpy
 % pabumpy <baseimage> <scale> <heavyness>

pawhirl
 % pawhirl <baseimage> <alpha> <beta> <gamma> <x:0-1> <y:0-1>

pamap
 % pamap <baseimage> [<mapimage>] [-col <r> <g> <b> <a>]

pascale
 % pascale <baseimage> <w> <h>
ie. 200 100 (absolute scale)
1.5x 1.2x (relative scale)
150 constrain (resize width to 150 and height accordingly)

pacut
 % pacut <baseimage> <x> <y> <w> <h>

pastars
 % pastars <baseimage> <freq:0.-10.> <bright:1.-4.>

padraw
 % padraw <baseimage> <commands>

This program has a small set of commands able to use:

<r> <g> <b> <a> setrgb
<x> <y> setp
<x> <y> getp
<x1> <y1> <x2> <y2> line
<x> <y> <w> <h> rect
<x> <y> <w> <h> fillrect
<x> <y> <rx> <ry> ellipse
<x> <y> <rx> <ry> fillellipse
<xN> <yN> <x1> <y1> <N> poly
<xN> <yN> <x1> <y1> <N> fillpoly

Sample:

 % padraw Samples/albuquerque.jpg "255 0 0 0 setrgb \ 
 20 10 40 80 line 0 0 255 128 setrgb \ 
 80 80 40 20 fillellipse" | xv - 

pafade
 % pafade <image1> <image2> <fade>

pasupernova
 % pasupernova <baseimage> <x:0-1> <y:0-1> <radius> <spokes> <sharp> <bright> <r> <g> <b>

paflip
 % paflip <image> [h|v|c]

pacat
 % pacat <image1> <image2> [h|v]

palight
 % palight <baseimage> <heightimage> <desc>
desc: point(255,255,255,2.0,1.5,-1.5)

pablend
 % pablend <image> <x0> <y0> <x1> <y1> <type> [<pallete-image]|<r0> <g0> <b0> <a0> <r1> <g1> <b1> <a1>]
type = linear (default), bilinear, radial
x and y are relative (0.0 - 1.0)

padraw3d
 % padraw3d <baseimage> <commands>

papick
 % papick <baseimage> <x> <y> <w> <h>

pamake
 % pamake <w> <h> <r> <g> <b> <a>

panoise
 % panoise <baseimage> <scale> <heavy> <r> <g> <b> <a>

patext-tt
 % patext-tt -p<points> -x<scale> -y<scale> -dpi<dpi> -fg<r>,<g>,<b> -bg<r>,<g>,<b> -f<font> <text>

patext-t1
 % patext-t1 -p<points> -x<scale> -y<scale> -dpi<dpi> -fg<r>,<g>,<b> -bg<r>,<g>,<b> -f<font> -w<width> <text>

painvert
 % painvert <image>

pafill
 % pafill <img> <r> <g> <b> <a> <x> <y> <tolerance>
tolerance <0-1>

paspread
 % paspread <baseimage> <depth>

pasmear
 % pasmear <baseimage> <size> <dir>

pamapxy
 % pamapxy <baseimage> <mapx> <mapy>

pastroke
 % pastroke <baseimage> <brushimg> <directionimg>

pahsl
 % pahsl <baseimage> <hue> <sat> <light>

pacontrast
 % pacontrast <baseimage> <contrast>

parotate
 % parotate <baseimage> <rot>
rot is in degrees (0..360)

PicArt: Programs
4. Resources

PicArt Cookbook
Further information of how to write stand-alone scripts and tricks

                                                                                                                                   

PicArtPicArt: Script

Last update 2001/07/16

All Rights Reserved - (C) 1997 - 2008 by The Labs.Com

Top of Page

The Labs.Com