version 1, including all changes.
.
Rev |
Author |
# |
Line |
1 |
perry |
1 |
ppmtoacad |
|
|
2 |
!!!ppmtoacad |
|
|
3 |
NAME |
|
|
4 |
SYNOPSIS |
|
|
5 |
DESCRIPTION |
|
|
6 |
OPTIONS |
|
|
7 |
BUGS |
|
|
8 |
SEE ALSO |
|
|
9 |
AUTHOR |
|
|
10 |
---- |
|
|
11 |
!!NAME |
|
|
12 |
|
|
|
13 |
|
|
|
14 |
ppmtoacad - convert portable pixmap to AutoCAD database or slide |
|
|
15 |
!!SYNOPSIS |
|
|
16 |
|
|
|
17 |
|
|
|
18 |
__ppmtoacad__ [[__-dxb__] [[__-poly__] |
|
|
19 |
[[__-background__ ''colour''] [[__-white__] |
|
|
20 |
[[__-aspect__ ''ratio''] [[__-8__] |
|
|
21 |
[[''ppmfile''] |
|
|
22 |
!!DESCRIPTION |
|
|
23 |
|
|
|
24 |
|
|
|
25 |
Reads a portable pixmap as input. Produces an AutoCAD slide |
|
|
26 |
file or binary database import (.dxb) file as output. If no |
|
|
27 |
''ppmfile'' is specified, input is read from standard |
|
|
28 |
input. |
|
|
29 |
!!OPTIONS |
|
|
30 |
|
|
|
31 |
|
|
|
32 |
__-dxb__ |
|
|
33 |
|
|
|
34 |
|
|
|
35 |
An AutoCAD binary database import (.dxb) file is written. |
|
|
36 |
This file is read with the DXBIN command and, once loaded, |
|
|
37 |
becomes part of the AutoCAD geometrical database and can be |
|
|
38 |
viewed and edited like any other object. Each sequence of |
|
|
39 |
identical pixels becomes a separate object in the database; |
|
|
40 |
this can result in very large AutoCAD drawing files. |
|
|
41 |
However, if you want to trace over a bitmap, it lets you |
|
|
42 |
zoom and pan around the bitmap as you wish. |
|
|
43 |
|
|
|
44 |
|
|
|
45 |
__-poly__ |
|
|
46 |
|
|
|
47 |
|
|
|
48 |
If the __-dxb__ option is not specified, the output of |
|
|
49 |
__ppmtoacad__ is an AutoCAD slide file. Normally each row |
|
|
50 |
of pixels is represented by an AutoCAD line entity. If |
|
|
51 |
__-poly__ is selected, the pixels are rendered as filled |
|
|
52 |
polygons. If the slide is viewed on a display with higher |
|
|
53 |
resolution than the source pixmap, this will cause the |
|
|
54 |
pixels to expand instead of appearing as discrete lines |
|
|
55 |
against the screen background colour. Regrettably, this |
|
|
56 |
representation yields slide files which occupy more disc |
|
|
57 |
space and take longer to display. |
|
|
58 |
|
|
|
59 |
|
|
|
60 |
__-background__ ''colour'' |
|
|
61 |
|
|
|
62 |
|
|
|
63 |
Most AutoCAD display drivers can be configured to use any |
|
|
64 |
available colour as the screen background. Some users perfer |
|
|
65 |
a black screen background, others white, while splinter |
|
|
66 |
groups advocate burnt ocher, tawny puce, and shocking grey. |
|
|
67 |
Discarding pixels whose closest AutoCAD colour |
|
|
68 |
representation is equal to the background colour can |
|
|
69 |
substantially reduce the size of the AutoCAD database or |
|
|
70 |
slide file needed to represent a bitmap. If no |
|
|
71 |
__-background__ colour is specified, the screen |
|
|
72 |
background colour is assumed to be black. Any AutoCAD colour |
|
|
73 |
number may be specified as the screen background; colour |
|
|
74 |
numbers are assumed to specify the hues defined in the |
|
|
75 |
standard AutoCAD 256 colour palette. |
|
|
76 |
|
|
|
77 |
|
|
|
78 |
__-white__ |
|
|
79 |
|
|
|
80 |
|
|
|
81 |
Since many AutoCAD users choose a white screen background, |
|
|
82 |
this option is provided as a short-cut. Specifying |
|
|
83 |
__-white__ is identical in effect to __-background |
|
|
84 |
7__. |
|
|
85 |
|
|
|
86 |
|
|
|
87 |
__-aspect__ ''ratio'' |
|
|
88 |
|
|
|
89 |
|
|
|
90 |
If the source pixmap had non-square pixels, the ratio of the |
|
|
91 |
pixel width to pixel height should be specified as |
|
|
92 |
''ratio''. The resulting slide or .dxb file will be |
|
|
93 |
corrected so that pixels on the AutoCAD screen will be |
|
|
94 |
square. For example, to correct an image made for a 320x200 |
|
|
95 |
VGA/MCGA screen, specify __-aspect 0.8333__. |
|
|
96 |
|
|
|
97 |
|
|
|
98 |
__-8__ |
|
|
99 |
|
|
|
100 |
|
|
|
101 |
Restricts the colours in the output file to the 8 RGB |
|
|
102 |
shades. |
|
|
103 |
|
|
|
104 |
|
|
|
105 |
All flags can be abbreviated to their shortest unique |
|
|
106 |
prefix. |
|
|
107 |
!!BUGS |
|
|
108 |
|
|
|
109 |
|
|
|
110 |
AutoCAD has a fixed palette of 256 colours, distributed |
|
|
111 |
along the hue, lightness, and saturation axes. Pixmaps which |
|
|
112 |
contain many nearly-identical colours, or colours not |
|
|
113 |
closely approximated by AutoCAD's palette, may be poorly |
|
|
114 |
rendered. |
|
|
115 |
|
|
|
116 |
|
|
|
117 |
__ppmtoacad__ works best if the system displaying its |
|
|
118 |
output supports the full 256 colour AutoCAD palette. |
|
|
119 |
Monochrome, 8 colour, and 16 colour configurations will |
|
|
120 |
produce less than optimal results. |
|
|
121 |
|
|
|
122 |
|
|
|
123 |
When creating a .dxb file or a slide file with the |
|
|
124 |
__-poly__ option, __ppmtoacad__ finds both vertical |
|
|
125 |
and horizontal runs of identical pixels and consolidates |
|
|
126 |
them into rectangular regions to reduce the size of the |
|
|
127 |
output file. This is effective for images with large areas |
|
|
128 |
of constant colour but it's no substitute for true raster to |
|
|
129 |
vector conversion. In particular, thin diagonal lines are |
|
|
130 |
not optimised at all by this process. |
|
|
131 |
|
|
|
132 |
|
|
|
133 |
Output files can be huge. |
|
|
134 |
!!SEE ALSO |
|
|
135 |
|
|
|
136 |
|
|
|
137 |
AutoCAD Reference Manual: ''Slide File Format'' and |
|
|
138 |
''Binary Drawing Interchange (DXB) Files'', |
|
|
139 |
ppm(5) |
|
|
140 |
!!AUTHOR |
|
|
141 |
|
|
|
142 |
|
|
|
143 |
John Walker |
|
|
144 |
Autodesk SA |
|
|
145 |
Avenue des Champs-Montants 14b |
|
|
146 |
CH-2074 MARIN |
|
|
147 |
Suisse/Schweiz/Svizzera/Svizra/Switzerland |
|
|
148 |
Usenet: |
|
|
149 |
kelvin@Autodesk.com |
|
|
150 |
Fax: |
|
|
151 |
038/33 88 15 |
|
|
152 |
Voice: |
|
|
153 |
038/33 76 33 |
|
|
154 |
|
|
|
155 |
|
|
|
156 |
Permission to use, copy, modify, and distribute this |
|
|
157 |
software and its documentation for any purpose and without |
|
|
158 |
fee is hereby granted, without any conditions or |
|
|
159 |
restrictions. This software is provided ``as is'' without |
|
|
160 |
express or implied warranty. |
|
|
161 |
|
|
|
162 |
|
|
|
163 |
AutoCAD and Autodesk are registered trademarks of Autodesk, |
|
|
164 |
Inc. |
|
|
165 |
---- |