File: jp2a.html

package info (click to toggle)
jp2a 1.0.6-2
  • links: PTS, VCS
  • area: main
  • in suites: lenny
  • size: 2,216 kB
  • ctags: 131
  • sloc: ansic: 1,006; sh: 895; makefile: 73
file content (800 lines) | stat: -rw-r--r-- 24,520 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
<!-- Creator     : groff version 1.19.1 -->
<!-- CreationDate: Mon Sep  4 13:51:17 2006 -->
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta name="generator" content="groff -Thtml, see www.gnu.org">
<meta http-equiv="Content-Type" content="text/html; charset=US-ASCII">
<meta name="Content-Style" content="text/css">
<title>jp2a</title>
</head>
<body>

<h1 align=center>jp2a</h1>
<a href="#NAME">NAME</a><br>
<a href="#SYNOPSIS">SYNOPSIS</a><br>
<a href="#DESCRIPTION">DESCRIPTION</a><br>
<a href="#OPTIONS">OPTIONS</a><br>
<a href="#RETURN VALUES">RETURN VALUES</a><br>
<a href="#EXAMPLES">EXAMPLES</a><br>
<a href="#DOWNLOADING IMAGES FROM THE NET">DOWNLOADING IMAGES FROM THE NET</a><br>
<a href="#GRAYSCALE CONVERSION">GRAYSCALE CONVERSION</a><br>
<a href="#PROJECT HOMEPAGE">PROJECT HOMEPAGE</a><br>
<a href="#SEE ALSO">SEE ALSO</a><br>
<a href="#BUGS">BUGS</a><br>
<a href="#AUTHOR">AUTHOR</a><br>
<a href="#LICENSE">LICENSE</a><br>

<hr>
<a name="NAME"></a>
<h2>NAME</h2>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p>jp2a &minus; convert JPEG images to ASCII</p>
</td>
</table>
<a name="SYNOPSIS"></a>
<h2>SYNOPSIS</h2>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p><b>jp2a</b> [ <i>options</i> ] [ <i>filename(s) |
URL(s)</i> ]</p>
</td>
</table>
<a name="DESCRIPTION"></a>
<h2>DESCRIPTION</h2>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p><b>jp2a</b> will convert JPEG images to ASCII characters.
You can specify a mixture of files and URLs.</p>
</td>
</table>
<a name="OPTIONS"></a>
<h2>OPTIONS</h2>
<!-- TABS -->
<table width="100%" border=0 rules="none" frame="void"
       cols="5" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="1%">

<p><b>&minus;</b></p>
</td>
<td width="10%"></td>
<td width="53%">

<p>Read JPEG image from standard input</p>
</td>
<td width="25%">
</td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p><b>&minus;&minus;background=light
&minus;&minus;background=dark</b></p></td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="22%"></td>
<td width="78%">
<p>If you don&rsquo;t want to mess with &minus;&minus;invert
all the time, just use these instead. If you are using white
characters on a black display, then use --background=dark,
and vice versa.</p>
</td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p><b>&minus;b &minus;&minus;border</b></p></td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="22%"></td>
<td width="78%">
<p>Frame output image in a border</p>
</td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p><b>&minus;&minus;chars=</b><i>...</i></p></td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="22%"></td>
<td width="78%">
<p>Use the given characters when producing the output ASCII
image. Default is &quot; ...&rsquo;,;:clodxkO0KXNWM&quot;.
<b>&minus;&minus;colors</b> Use ANSI color for text output
and CSS color for HTML output.</p>
</td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p><b>&minus;d &minus;&minus;debug</b></p></td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="22%"></td>
<td width="78%">
<p>Print debugging information when using libcurl to
download images from the net.</p>
</td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p><b>&minus;f &minus;&minus;term&minus;fit</b></p></td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="22%"></td>
<td width="78%">
<p>Use the largest dimension that makes the image fit in
your terminal display.</p>
</td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p><b>&minus;&minus;term&minus;height</b></p></td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="22%"></td>
<td width="78%">
<p>Use terminal display height and calculate width based on
image aspect ratio.</p>
</td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p><b>&minus;&minus;term&minus;width</b></p></td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="22%"></td>
<td width="78%">
<p>Use terminal display width and calculate height based on
image aspect ratio.</p>
</td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p><b>&minus;z &minus;&minus;term&minus;zoom</b></p></td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="22%"></td>
<td width="78%">
<p>Use terminal display width and height.</p>
</td>
</table>
<!-- TABS -->
<table width="100%" border=0 rules="none" frame="void"
       cols="4" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="9%">

<p><b>&minus;&minus;fill</b></p>
</td>
<td width="2%"></td>
<td width="78%">

<p>When used with &minus;&minus;html and
&minus;&minus;color, then color each output
character&rsquo;s background color. For instance, if you
want to use fill-output on a light background, do</p>
</td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p>jp2a --color --html --html-fill --background=light
somefile.jpg --output=dark.html</p>
<!-- INDENTATION -->
<p>To do the same on a light background:</p>
<!-- INDENTATION -->
<p>jp2a --color --html --html-fill --background=dark
somefile.jpg --output=light.html</p>
<!-- INDENTATION -->
<p>The default is to have fill disabled.</p>
</td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p><b>&minus;x &minus;&minus;flipx</b></p></td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="22%"></td>
<td width="78%">
<p>Flip output image horizontally</p>
</td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p><b>&minus;y &minus;&minus;flipy</b></p></td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="22%"></td>
<td width="78%">
<p>Flip output image vertically</p>
</td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p><b>&minus;&minus;height=</b><i>N</i></p></td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="22%"></td>
<td width="78%">
<p>Set output height. If only --height is specified, then
output width will be calculated according to the source
images aspect ratio.</p>
</td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p><b>&minus;h &minus;&minus;help</b></p></td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="22%"></td>
<td width="78%">
<p>Display a short help text</p>
</td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p><b>&minus;&minus;grayscale</b></p></td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="22%"></td>
<td width="78%">
<p>Converts image to grayscale when using &minus;&minus;html
or &minus;&minus;colors.</p>
</td>
</table>
<!-- TABS -->
<table width="100%" border=0 rules="none" frame="void"
       cols="4" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="9%">

<p><b>&minus;&minus;html</b></p>
</td>
<td width="2%"></td>
<td width="78%">

<p>Make ASCII output in strict XHTML 1.0, suitable for
viewing with web browsers. This is useful with big output
dimensions, and you want to check the result with a browser
with small font.</p>
</td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p><b>&minus;&minus;html&minus;fill</b></p></td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="22%"></td>
<td width="78%">
<p>Same as &minus;&minus;fill. You should use that option
instead.</p>
</td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p><b>&minus;&minus;html&minus;no&minus;bold</b></p></td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="22%"></td>
<td width="78%">
<p>Do not use bold text for HTML output.</p>
</td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p><b>&minus;&minus;html&minus;raw</b></p></td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="22%"></td>
<td width="78%">
<p>Output only the image in HTML codes, leaving out the rest
of the webpage, so you can construct your own.</p>
</td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">

<p><b>&minus;&minus;html&minus;fontsize=</b><i>N</i></p></td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="22%"></td>
<td width="78%">
<p>Set fontsize when using &minus;&minus;html output.
Default is 4.</p>
</td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">

<p><b>&minus;&minus;html&minus;title=</b><i>...</i></p></td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="22%"></td>
<td width="78%">
<p>Set HTML output title.</p>
</td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p><b>&minus;&minus;output=...</b></p></td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="22%"></td>
<td width="78%">
<p>Write ASCII output to given filename. To explicitly
specify standard output, use
&minus;&minus;output=&minus;.</p>
</td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p><b>&minus;i &minus;&minus;invert</b></p></td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="22%"></td>
<td width="78%">
<p>Invert output image. If you view a picture with white
background, but you are using a display with light
characters on a dark background, you shoudl invert the
image.</p>
</td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p><b>&minus;&minus;red=</b><i>...</i></p></td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p><b>&minus;&minus;green=</b><i>...</i></p></td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p><b>&minus;&minus;blue=</b><i>...</i></p></td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="22%"></td>
<td width="78%">
<p>When converting from RGB to grayscale, use the given
weights to calculate luminance. These three floating point
values must add up to exactly 1.0. The default is
red=0.2989, green=0.5866 and blue=0.1145.</p>
</td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p><b>&minus;&minus;size=</b><i>WIDTHxHEIGHT</i></p></td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="22%"></td>
<td width="78%">
<p>Set output dimension.</p>
</td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p><b>&minus;v &minus;&minus;verbose</b></p></td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="22%"></td>
<td width="78%">
<p>Print some verbose information to standard error when
reading each JPEG image.</p>
</td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p><b>&minus;&minus;width=</b><i>N</i></p></td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="22%"></td>
<td width="78%">
<p>Set output width. If you only specify the width, the
height will be calculated automatically.</p>
</td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p><b>&minus;V &minus;&minus;version</b></p></td>
</table>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="22%"></td>
<td width="78%">
<p>Print program version.</p>
</td>
</table>
<!-- TABS -->
<table width="100%" border=0 rules="none" frame="void"
       cols="4" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="9%">

<p><b>&minus;&minus;zoom</b></p>
</td>
<td width="2%"></td>
<td width="78%">

<p>Sets output dimensions to your entire terminal window,
disregarding source image aspect ratio.</p>
</td>
</table>
<a name="RETURN VALUES"></a>
<h2>RETURN VALUES</h2>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p>jp2a returns 1 when errors are encountered, zero for no
errors.</p>
</td>
</table>
<a name="EXAMPLES"></a>
<h2>EXAMPLES</h2>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p>Convert and print imagefile.jpg using ASCII characters in
40 columns and 20 rows:</p>
<!-- INDENTATION -->
<p><b>jp2a</b> &minus;&minus;size=40x20 imagefile.jpg</p>
<!-- INDENTATION -->
<p>Download an image off the net, convert and print:</p>
<!-- INDENTATION -->
<p><b>jp2a</b>
http://www.google.com/intl/en/logos/easter_logo.jpg</p>
<!-- INDENTATION -->
<p>Output picture.jpg and picture2.jpg, each 80x25
characters, using the characters &quot; ...ooxx@@&quot; for
output:</p>
<!-- INDENTATION -->
<p><b>jp2a</b> &minus;&minus;size=80x25 --chars=&quot;
...ooxx@@&quot; picture.jpg picture2.jpg</p>
<!-- INDENTATION -->
<p>Output image.jpg using 76 columns, height is
automatically calculated from aspect ratio of image.jpg</p>
<!-- INDENTATION -->
<p>cat image.jpg | <b>jp2a</b> &minus;&minus;width=76
&minus;</p>
<!-- INDENTATION -->
<p>If you use jp2a together with ImageMagick&rsquo;s
convert(1) then you can make good use of pipes, and have
ImageMagick do all sorts of image conversions and effects on
the source image. For example:</p>
<!-- INDENTATION -->
<p><b>convert</b> somefile.png jpg:&minus; | <b>jp2a</b>
&minus; &minus;&minus;width=80</p>
<!-- INDENTATION -->
<p>Check out convert(1) options to see what you can do.
Convert can handle almost any image format, so with this
combination you can convert images in e.g. PDF or AVI files
to ASCII.</p>
<!-- INDENTATION -->
<p>Although the default build of jp2a includes automatic
downloading of files specified by URLs, you can explicitly
download them by using curl(1) or wget(1), for example:</p>
<!-- INDENTATION -->
<p><b>curl</b> &minus;s http://foo.bar/image.jpg |
<b>convert</b> &minus; jpg:- | <b>jp2a</b> &minus;</p>
</td>
</table>
<a name="DOWNLOADING IMAGES FROM THE NET"></a>
<h2>DOWNLOADING IMAGES FROM THE NET</h2>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p>If you have compiled jp2a with libcurl(3), you can
download images by specifying URLs:</p>
<!-- INDENTATION -->
<p><b>jp2a</b> https://user:pass@foo.com/bar.jpg</p>
<!-- INDENTATION -->
<p>The protocols recognized are ftp, ftps, file, http, https
and tftp.</p>
<!-- INDENTATION -->
<p>If you need more control of the downloading, you should
use curl(1) or wget(1) and jp2a read the image from standard
input.</p>
<!-- INDENTATION -->
<p>jp2a uses pipe and fork to download images using libcurl
(i.e., no exec or system calls) and therefore does not worry
about malevolently formatted URLs.</p>
</td>
</table>
<a name="GRAYSCALE CONVERSION"></a>
<h2>GRAYSCALE CONVERSION</h2>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p>You can extract the red channel by doing this:</p>
<!-- INDENTATION -->
<p><b>jp2a</b> somefile.jpg --red=1.0 --green=0.0
--blue=0.0</p>
<!-- INDENTATION -->
<p>This will calculate luminance based on Y = R*1.0 + G*0.0
+ B*0.0. The default values is to use Y = R*0.2989 +
G*0.5866 + B*0.1145.</p>
</td>
</table>
<a name="PROJECT HOMEPAGE"></a>
<h2>PROJECT HOMEPAGE</h2>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p>The latest version of jp2a and news is always available
from http://jp2a.sourceforge.net</p>
</td>
</table>
<a name="SEE ALSO"></a>
<h2>SEE ALSO</h2>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p>cjpeg(1), djpeg(1), jpegtran(1), convert(1)</p>
</td>
</table>
<a name="BUGS"></a>
<h2>BUGS</h2>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p>jp2a does not interpolate when resizing. If you want
better quality, try using convert(1) and convert the source
image to the exact output dimensions before using jp2a.</p>
<!-- INDENTATION -->
<p>Another issue is that jp2a skips some X-pixels along each
scanline. This gives a less precise output image, and will
probably be corrected in future versions.</p>
</td>
</table>
<a name="AUTHOR"></a>
<h2>AUTHOR</h2>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p>Christian Stigen Larsen &lt;csl@sublevel3.org&gt; --
http://csl.sublevel3.org</p>
<!-- INDENTATION -->
<p>jp2a uses jpeglib to read JPEG files. jpeglib is made by
The Independent JPEG Group (IJG), who have a page at
http://www.ijg.org</p>
</td>
</table>
<a name="LICENSE"></a>
<h2>LICENSE</h2>
<!-- INDENTATION -->
<table width="100%" border=0 rules="none" frame="void"
       cols="2" cellspacing="0" cellpadding="0">
<tr valign="top" align="left">
<td width="11%"></td>
<td width="89%">
<p>jp2a is distributed under the GNU General Public License
v2.</p>
</td>
</table>
<hr>
</body>
</html>