aboutsummaryrefslogtreecommitdiff
path: root/java/doc/org/libjpegturbo/turbojpeg/TJ.html
blob: ffef65786399a80b7f16ea2fa42f745c44fe885b (plain)
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
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!-- NewPage -->
<html lang="en">
<head>
<title>TJ</title>
<link rel="stylesheet" type="text/css" href="../../../stylesheet.css" title="Style">
</head>
<body>
<script type="text/javascript"><!--
    if (location.href.indexOf('is-external=true') == -1) {
        parent.document.title="TJ";
    }
//-->
</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
<!-- ========= START OF TOP NAVBAR ======= -->
<div class="topNav"><a name="navbar_top">
<!--   -->
</a><a href="#skip-navbar_top" title="Skip navigation links"></a><a name="navbar_top_firstrow">
<!--   -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../org/libjpegturbo/turbojpeg/package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../index-all.html">Index</a></li>
<li><a href="../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li>Prev Class</li>
<li><a href="../../../org/libjpegturbo/turbojpeg/TJCompressor.html" title="class in org.libjpegturbo.turbojpeg"><span class="strong">Next Class</span></a></li>
</ul>
<ul class="navList">
<li><a href="../../../index.html?org/libjpegturbo/turbojpeg/TJ.html" target="_top">Frames</a></li>
<li><a href="TJ.html" target="_top">No Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_top">
<li><a href="../../../allclasses-noframe.html">All Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
  allClassesLink = document.getElementById("allclasses_navbar_top");
  if(window==top) {
    allClassesLink.style.display = "block";
  }
  else {
    allClassesLink.style.display = "none";
  }
  //-->
</script>
</div>
<div>
<ul class="subNavList">
<li>Summary:&nbsp;</li>
<li>Nested&nbsp;|&nbsp;</li>
<li><a href="#field_summary">Field</a>&nbsp;|&nbsp;</li>
<li><a href="#constructor_summary">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method_summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li><a href="#field_detail">Field</a>&nbsp;|&nbsp;</li>
<li><a href="#constructor_detail">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method_detail">Method</a></li>
</ul>
</div>
<a name="skip-navbar_top">
<!--   -->
</a></div>
<!-- ========= END OF TOP NAVBAR ========= -->
<!-- ======== START OF CLASS DATA ======== -->
<div class="header">
<div class="subTitle">org.libjpegturbo.turbojpeg</div>
<h2 title="Class TJ" class="title">Class TJ</h2>
</div>
<div class="contentContainer">
<ul class="inheritance">
<li>java.lang.Object</li>
<li>
<ul class="inheritance">
<li>org.libjpegturbo.turbojpeg.TJ</li>
</ul>
</li>
</ul>
<div class="description">
<ul class="blockList">
<li class="blockList">
<hr>
<br>
<pre>public final class <span class="strong">TJ</span>
extends java.lang.Object</pre>
<div class="block">TurboJPEG utility class (cannot be instantiated)</div>
</li>
</ul>
</div>
<div class="summary">
<ul class="blockList">
<li class="blockList">
<!-- =========== FIELD SUMMARY =========== -->
<ul class="blockList">
<li class="blockList"><a name="field_summary">
<!--   -->
</a>
<h3>Field Summary</h3>
<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Field Summary table, listing fields, and an explanation">
<caption><span>Fields</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th class="colLast" scope="col">Field and Description</th>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#CS_CMYK">CS_CMYK</a></strong></code>
<div class="block">CMYK colorspace.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#CS_GRAY">CS_GRAY</a></strong></code>
<div class="block">Grayscale colorspace.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#CS_RGB">CS_RGB</a></strong></code>
<div class="block">RGB colorspace.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#CS_YCbCr">CS_YCbCr</a></strong></code>
<div class="block">YCbCr colorspace.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#CS_YCCK">CS_YCCK</a></strong></code>
<div class="block">YCCK colorspace.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#FLAG_ACCURATEDCT">FLAG_ACCURATEDCT</a></strong></code>
<div class="block">Use the most accurate DCT/IDCT algorithm available in the underlying
 codec.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#FLAG_BOTTOMUP">FLAG_BOTTOMUP</a></strong></code>
<div class="block">The uncompressed source/destination image is stored in bottom-up (Windows,
 OpenGL) order, not top-down (X11) order.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#FLAG_FASTDCT">FLAG_FASTDCT</a></strong></code>
<div class="block">Use the fastest DCT/IDCT algorithm available in the underlying codec.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#FLAG_FASTUPSAMPLE">FLAG_FASTUPSAMPLE</a></strong></code>
<div class="block">When decompressing an image that was compressed using chrominance
 subsampling, use the fastest chrominance upsampling algorithm available in
 the underlying codec.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#FLAG_FORCEMMX">FLAG_FORCEMMX</a></strong></code>
<div class="block"><strong>Deprecated.</strong>&nbsp;</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#FLAG_FORCESSE">FLAG_FORCESSE</a></strong></code>
<div class="block"><strong>Deprecated.</strong>&nbsp;</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#FLAG_FORCESSE2">FLAG_FORCESSE2</a></strong></code>
<div class="block"><strong>Deprecated.</strong>&nbsp;</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#FLAG_FORCESSE3">FLAG_FORCESSE3</a></strong></code>
<div class="block"><strong>Deprecated.</strong>&nbsp;</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#NUMCS">NUMCS</a></strong></code>
<div class="block">The number of JPEG colorspaces</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#NUMPF">NUMPF</a></strong></code>
<div class="block">The number of pixel formats</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#NUMSAMP">NUMSAMP</a></strong></code>
<div class="block">The number of chrominance subsampling options</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#PF_ABGR">PF_ABGR</a></strong></code>
<div class="block">ABGR pixel format.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#PF_ARGB">PF_ARGB</a></strong></code>
<div class="block">ARGB pixel format.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#PF_BGR">PF_BGR</a></strong></code>
<div class="block">BGR pixel format.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#PF_BGRA">PF_BGRA</a></strong></code>
<div class="block">BGRA pixel format.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#PF_BGRX">PF_BGRX</a></strong></code>
<div class="block">BGRX pixel format.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#PF_CMYK">PF_CMYK</a></strong></code>
<div class="block">CMYK pixel format.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#PF_GRAY">PF_GRAY</a></strong></code>
<div class="block">Grayscale pixel format.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#PF_RGB">PF_RGB</a></strong></code>
<div class="block">RGB pixel format.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#PF_RGBA">PF_RGBA</a></strong></code>
<div class="block">RGBA pixel format.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#PF_RGBX">PF_RGBX</a></strong></code>
<div class="block">RGBX pixel format.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#PF_XBGR">PF_XBGR</a></strong></code>
<div class="block">XBGR pixel format.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#PF_XRGB">PF_XRGB</a></strong></code>
<div class="block">XRGB pixel format.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#SAMP_411">SAMP_411</a></strong></code>
<div class="block">4:1:1 chrominance subsampling.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#SAMP_420">SAMP_420</a></strong></code>
<div class="block">4:2:0 chrominance subsampling.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#SAMP_422">SAMP_422</a></strong></code>
<div class="block">4:2:2 chrominance subsampling.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#SAMP_440">SAMP_440</a></strong></code>
<div class="block">4:4:0 chrominance subsampling.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#SAMP_444">SAMP_444</a></strong></code>
<div class="block">4:4:4 chrominance subsampling (no chrominance subsampling).</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#SAMP_GRAY">SAMP_GRAY</a></strong></code>
<div class="block">Grayscale.</div>
</td>
</tr>
</table>
</li>
</ul>
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
<ul class="blockList">
<li class="blockList"><a name="constructor_summary">
<!--   -->
</a>
<h3>Constructor Summary</h3>
<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Constructor Summary table, listing constructors, and an explanation">
<caption><span>Constructors</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colOne" scope="col">Constructor and Description</th>
</tr>
<tr class="altColor">
<td class="colOne"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#TJ()">TJ</a></strong>()</code>&nbsp;</td>
</tr>
</table>
</li>
</ul>
<!-- ========== METHOD SUMMARY =========== -->
<ul class="blockList">
<li class="blockList"><a name="method_summary">
<!--   -->
</a>
<h3>Method Summary</h3>
<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation">
<caption><span>Methods</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th class="colLast" scope="col">Method and Description</th>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#bufSize(int,%20int,%20int)">bufSize</a></strong>(int&nbsp;width,
       int&nbsp;height,
       int&nbsp;jpegSubsamp)</code>
<div class="block">Returns the maximum size of the buffer (in bytes) required to hold a JPEG
 image with the given width, height, and level of chrominance subsampling.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#bufSizeYUV(int,%20int,%20int)">bufSizeYUV</a></strong>(int&nbsp;width,
          int&nbsp;height,
          int&nbsp;subsamp)</code>
<div class="block"><strong>Deprecated.</strong>&nbsp;
<div class="block"><i>Use <a href="../../../org/libjpegturbo/turbojpeg/TJ.html#bufSizeYUV(int,%20int,%20int,%20int)"><code>bufSizeYUV(int, int, int, int)</code></a> instead.</i></div>
</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#bufSizeYUV(int,%20int,%20int,%20int)">bufSizeYUV</a></strong>(int&nbsp;width,
          int&nbsp;pad,
          int&nbsp;height,
          int&nbsp;subsamp)</code>
<div class="block">Returns the size of the buffer (in bytes) required to hold a YUV planar
 image with the given width, height, and level of chrominance subsampling.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#getBlueOffset(int)">getBlueOffset</a></strong>(int&nbsp;pixelFormat)</code>
<div class="block">For the given pixel format, returns the number of bytes that the blue
 component is offset from the start of the pixel.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#getGreenOffset(int)">getGreenOffset</a></strong>(int&nbsp;pixelFormat)</code>
<div class="block">For the given pixel format, returns the number of bytes that the green
 component is offset from the start of the pixel.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#getMCUHeight(int)">getMCUHeight</a></strong>(int&nbsp;subsamp)</code>
<div class="block">Returns the MCU block height for the given level of chrominance
 subsampling.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#getMCUWidth(int)">getMCUWidth</a></strong>(int&nbsp;subsamp)</code>
<div class="block">Returns the MCU block width for the given level of chrominance
 subsampling.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#getPixelSize(int)">getPixelSize</a></strong>(int&nbsp;pixelFormat)</code>
<div class="block">Returns the pixel size (in bytes) for the given pixel format.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#getRedOffset(int)">getRedOffset</a></strong>(int&nbsp;pixelFormat)</code>
<div class="block">For the given pixel format, returns the number of bytes that the red
 component is offset from the start of the pixel.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static <a href="../../../org/libjpegturbo/turbojpeg/TJScalingFactor.html" title="class in org.libjpegturbo.turbojpeg">TJScalingFactor</a>[]</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#getScalingFactors()">getScalingFactors</a></strong>()</code>
<div class="block">Returns a list of fractional scaling factors that the JPEG decompressor in
 this implementation of TurboJPEG supports.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#planeHeight(int,%20int,%20int)">planeHeight</a></strong>(int&nbsp;componentID,
           int&nbsp;height,
           int&nbsp;subsamp)</code>
<div class="block">Returns the plane height of a YUV image plane with the given parameters.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#planeSizeYUV(int,%20int,%20int,%20int,%20int)">planeSizeYUV</a></strong>(int&nbsp;componentID,
            int&nbsp;width,
            int&nbsp;stride,
            int&nbsp;height,
            int&nbsp;subsamp)</code>
<div class="block">Returns the size of the buffer (in bytes) required to hold a YUV image
 plane with the given parameters.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#planeWidth(int,%20int,%20int)">planeWidth</a></strong>(int&nbsp;componentID,
          int&nbsp;width,
          int&nbsp;subsamp)</code>
<div class="block">Returns the plane width of a YUV image plane with the given parameters.</div>
</td>
</tr>
</table>
<ul class="blockList">
<li class="blockList"><a name="methods_inherited_from_class_java.lang.Object">
<!--   -->
</a>
<h3>Methods inherited from class&nbsp;java.lang.Object</h3>
<code>clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait</code></li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
<div class="details">
<ul class="blockList">
<li class="blockList">
<!-- ============ FIELD DETAIL =========== -->
<ul class="blockList">
<li class="blockList"><a name="field_detail">
<!--   -->
</a>
<h3>Field Detail</h3>
<a name="NUMSAMP">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>NUMSAMP</h4>
<pre>public static final&nbsp;int NUMSAMP</pre>
<div class="block">The number of chrominance subsampling options</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.NUMSAMP">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="SAMP_444">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SAMP_444</h4>
<pre>public static final&nbsp;int SAMP_444</pre>
<div class="block">4:4:4 chrominance subsampling (no chrominance subsampling).  The JPEG
 or YUV image will contain one chrominance component for every pixel in the
 source image.</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.SAMP_444">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="SAMP_422">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SAMP_422</h4>
<pre>public static final&nbsp;int SAMP_422</pre>
<div class="block">4:2:2 chrominance subsampling.  The JPEG or YUV image will contain one
 chrominance component for every 2x1 block of pixels in the source image.</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.SAMP_422">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="SAMP_420">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SAMP_420</h4>
<pre>public static final&nbsp;int SAMP_420</pre>
<div class="block">4:2:0 chrominance subsampling.  The JPEG or YUV image will contain one
 chrominance component for every 2x2 block of pixels in the source image.</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.SAMP_420">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="SAMP_GRAY">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SAMP_GRAY</h4>
<pre>public static final&nbsp;int SAMP_GRAY</pre>
<div class="block">Grayscale.  The JPEG or YUV image will contain no chrominance components.</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.SAMP_GRAY">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="SAMP_440">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SAMP_440</h4>
<pre>public static final&nbsp;int SAMP_440</pre>
<div class="block">4:4:0 chrominance subsampling.  The JPEG or YUV image will contain one
 chrominance component for every 1x2 block of pixels in the source image.
 Note that 4:4:0 subsampling is not fully accelerated in libjpeg-turbo.</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.SAMP_440">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="SAMP_411">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SAMP_411</h4>
<pre>public static final&nbsp;int SAMP_411</pre>
<div class="block">4:1:1 chrominance subsampling.  The JPEG or YUV image will contain one
 chrominance component for every 4x1 block of pixels in the source image.
 JPEG images compressed with 4:1:1 subsampling will be almost exactly the
 same size as those compressed with 4:2:0 subsampling, and in the
 aggregate, both subsampling methods produce approximately the same
 perceptual quality.  However, 4:1:1 is better able to reproduce sharp
 horizontal features.  Note that 4:1:1 subsampling is not fully accelerated
 in libjpeg-turbo.</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.SAMP_411">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="NUMPF">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>NUMPF</h4>
<pre>public static final&nbsp;int NUMPF</pre>
<div class="block">The number of pixel formats</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.NUMPF">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="PF_RGB">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>PF_RGB</h4>
<pre>public static final&nbsp;int PF_RGB</pre>
<div class="block">RGB pixel format.  The red, green, and blue components in the image are
 stored in 3-byte pixels in the order R, G, B from lowest to highest byte
 address within each pixel.</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.PF_RGB">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="PF_BGR">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>PF_BGR</h4>
<pre>public static final&nbsp;int PF_BGR</pre>
<div class="block">BGR pixel format.  The red, green, and blue components in the image are
 stored in 3-byte pixels in the order B, G, R from lowest to highest byte
 address within each pixel.</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.PF_BGR">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="PF_RGBX">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>PF_RGBX</h4>
<pre>public static final&nbsp;int PF_RGBX</pre>
<div class="block">RGBX pixel format.  The red, green, and blue components in the image are
 stored in 4-byte pixels in the order R, G, B from lowest to highest byte
 address within each pixel.  The X component is ignored when compressing
 and undefined when decompressing.</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.PF_RGBX">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="PF_BGRX">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>PF_BGRX</h4>
<pre>public static final&nbsp;int PF_BGRX</pre>
<div class="block">BGRX pixel format.  The red, green, and blue components in the image are
 stored in 4-byte pixels in the order B, G, R from lowest to highest byte
 address within each pixel.  The X component is ignored when compressing
 and undefined when decompressing.</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.PF_BGRX">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="PF_XBGR">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>PF_XBGR</h4>
<pre>public static final&nbsp;int PF_XBGR</pre>
<div class="block">XBGR pixel format.  The red, green, and blue components in the image are
 stored in 4-byte pixels in the order R, G, B from highest to lowest byte
 address within each pixel.  The X component is ignored when compressing
 and undefined when decompressing.</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.PF_XBGR">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="PF_XRGB">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>PF_XRGB</h4>
<pre>public static final&nbsp;int PF_XRGB</pre>
<div class="block">XRGB pixel format.  The red, green, and blue components in the image are
 stored in 4-byte pixels in the order B, G, R from highest to lowest byte
 address within each pixel.  The X component is ignored when compressing
 and undefined when decompressing.</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.PF_XRGB">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="PF_GRAY">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>PF_GRAY</h4>
<pre>public static final&nbsp;int PF_GRAY</pre>
<div class="block">Grayscale pixel format.  Each 1-byte pixel represents a luminance
 (brightness) level from 0 to 255.</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.PF_GRAY">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="PF_RGBA">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>PF_RGBA</h4>
<pre>public static final&nbsp;int PF_RGBA</pre>
<div class="block">RGBA pixel format.  This is the same as <a href="../../../org/libjpegturbo/turbojpeg/TJ.html#PF_RGBX"><code>PF_RGBX</code></a>, except that when
 decompressing, the X byte is guaranteed to be 0xFF, which can be
 interpreted as an opaque alpha channel.</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.PF_RGBA">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="PF_BGRA">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>PF_BGRA</h4>
<pre>public static final&nbsp;int PF_BGRA</pre>
<div class="block">BGRA pixel format.  This is the same as <a href="../../../org/libjpegturbo/turbojpeg/TJ.html#PF_BGRX"><code>PF_BGRX</code></a>, except that when
 decompressing, the X byte is guaranteed to be 0xFF, which can be
 interpreted as an opaque alpha channel.</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.PF_BGRA">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="PF_ABGR">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>PF_ABGR</h4>
<pre>public static final&nbsp;int PF_ABGR</pre>
<div class="block">ABGR pixel format.  This is the same as <a href="../../../org/libjpegturbo/turbojpeg/TJ.html#PF_XBGR"><code>PF_XBGR</code></a>, except that when
 decompressing, the X byte is guaranteed to be 0xFF, which can be
 interpreted as an opaque alpha channel.</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.PF_ABGR">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="PF_ARGB">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>PF_ARGB</h4>
<pre>public static final&nbsp;int PF_ARGB</pre>
<div class="block">ARGB pixel format.  This is the same as <a href="../../../org/libjpegturbo/turbojpeg/TJ.html#PF_XRGB"><code>PF_XRGB</code></a>, except that when
 decompressing, the X byte is guaranteed to be 0xFF, which can be
 interpreted as an opaque alpha channel.</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.PF_ARGB">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="PF_CMYK">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>PF_CMYK</h4>
<pre>public static final&nbsp;int PF_CMYK</pre>
<div class="block">CMYK pixel format.  Unlike RGB, which is an additive color model used
 primarily for display, CMYK (Cyan/Magenta/Yellow/Key) is a subtractive
 color model used primarily for printing.  In the CMYK color model, the
 value of each color component typically corresponds to an amount of cyan,
 magenta, yellow, or black ink that is applied to a white background.  In
 order to convert between CMYK and RGB, it is necessary to use a color
 management system (CMS.)  A CMS will attempt to map colors within the
 printer's gamut to perceptually similar colors in the display's gamut and
 vice versa, but the mapping is typically not 1:1 or reversible, nor can it
 be defined with a simple formula.  Thus, such a conversion is out of scope
 for a codec library.  However, the TurboJPEG API allows for compressing
 CMYK pixels into a YCCK JPEG image (see <a href="../../../org/libjpegturbo/turbojpeg/TJ.html#CS_YCCK"><code>CS_YCCK</code></a>) and
 decompressing YCCK JPEG images into CMYK pixels.</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.PF_CMYK">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="NUMCS">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>NUMCS</h4>
<pre>public static final&nbsp;int NUMCS</pre>
<div class="block">The number of JPEG colorspaces</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.NUMCS">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="CS_RGB">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>CS_RGB</h4>
<pre>public static final&nbsp;int CS_RGB</pre>
<div class="block">RGB colorspace.  When compressing the JPEG image, the R, G, and B
 components in the source image are reordered into image planes, but no
 colorspace conversion or subsampling is performed.  RGB JPEG images can be
 decompressed to any of the extended RGB pixel formats or grayscale, but
 they cannot be decompressed to YUV images.</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.CS_RGB">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="CS_YCbCr">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>CS_YCbCr</h4>
<pre>public static final&nbsp;int CS_YCbCr</pre>
<div class="block">YCbCr colorspace.  YCbCr is not an absolute colorspace but rather a
 mathematical transformation of RGB designed solely for storage and
 transmission.  YCbCr images must be converted to RGB before they can
 actually be displayed.  In the YCbCr colorspace, the Y (luminance)
 component represents the black & white portion of the original image, and
 the Cb and Cr (chrominance) components represent the color portion of the
 original image.  Originally, the analog equivalent of this transformation
 allowed the same signal to drive both black & white and color televisions,
 but JPEG images use YCbCr primarily because it allows the color data to be
 optionally subsampled for the purposes of reducing bandwidth or disk
 space.  YCbCr is the most common JPEG colorspace, and YCbCr JPEG images
 can be compressed from and decompressed to any of the extended RGB pixel
 formats or grayscale, or they can be decompressed to YUV planar images.</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.CS_YCbCr">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="CS_GRAY">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>CS_GRAY</h4>
<pre>public static final&nbsp;int CS_GRAY</pre>
<div class="block">Grayscale colorspace.  The JPEG image retains only the luminance data (Y
 component), and any color data from the source image is discarded.
 Grayscale JPEG images can be compressed from and decompressed to any of
 the extended RGB pixel formats or grayscale, or they can be decompressed
 to YUV planar images.</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.CS_GRAY">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="CS_CMYK">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>CS_CMYK</h4>
<pre>public static final&nbsp;int CS_CMYK</pre>
<div class="block">CMYK colorspace.  When compressing the JPEG image, the C, M, Y, and K
 components in the source image are reordered into image planes, but no
 colorspace conversion or subsampling is performed.  CMYK JPEG images can
 only be decompressed to CMYK pixels.</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.CS_CMYK">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="CS_YCCK">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>CS_YCCK</h4>
<pre>public static final&nbsp;int CS_YCCK</pre>
<div class="block">YCCK colorspace.  YCCK (AKA "YCbCrK") is not an absolute colorspace but
 rather a mathematical transformation of CMYK designed solely for storage
 and transmission.  It is to CMYK as YCbCr is to RGB.  CMYK pixels can be
 reversibly transformed into YCCK, and as with YCbCr, the chrominance
 components in the YCCK pixels can be subsampled without incurring major
 perceptual loss.  YCCK JPEG images can only be compressed from and
 decompressed to CMYK pixels.</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.CS_YCCK">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="FLAG_BOTTOMUP">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>FLAG_BOTTOMUP</h4>
<pre>public static final&nbsp;int FLAG_BOTTOMUP</pre>
<div class="block">The uncompressed source/destination image is stored in bottom-up (Windows,
 OpenGL) order, not top-down (X11) order.</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.FLAG_BOTTOMUP">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="FLAG_FORCEMMX">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>FLAG_FORCEMMX</h4>
<pre>@Deprecated
public static final&nbsp;int FLAG_FORCEMMX</pre>
<div class="block"><span class="strong">Deprecated.</span>&nbsp;</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.FLAG_FORCEMMX">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="FLAG_FORCESSE">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>FLAG_FORCESSE</h4>
<pre>@Deprecated
public static final&nbsp;int FLAG_FORCESSE</pre>
<div class="block"><span class="strong">Deprecated.</span>&nbsp;</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.FLAG_FORCESSE">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="FLAG_FORCESSE2">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>FLAG_FORCESSE2</h4>
<pre>@Deprecated
public static final&nbsp;int FLAG_FORCESSE2</pre>
<div class="block"><span class="strong">Deprecated.</span>&nbsp;</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.FLAG_FORCESSE2">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="FLAG_FORCESSE3">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>FLAG_FORCESSE3</h4>
<pre>@Deprecated
public static final&nbsp;int FLAG_FORCESSE3</pre>
<div class="block"><span class="strong">Deprecated.</span>&nbsp;</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.FLAG_FORCESSE3">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="FLAG_FASTUPSAMPLE">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>FLAG_FASTUPSAMPLE</h4>
<pre>public static final&nbsp;int FLAG_FASTUPSAMPLE</pre>
<div class="block">When decompressing an image that was compressed using chrominance
 subsampling, use the fastest chrominance upsampling algorithm available in
 the underlying codec.  The default is to use smooth upsampling, which
 creates a smooth transition between neighboring chrominance components in
 order to reduce upsampling artifacts in the decompressed image.</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.FLAG_FASTUPSAMPLE">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="FLAG_FASTDCT">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>FLAG_FASTDCT</h4>
<pre>public static final&nbsp;int FLAG_FASTDCT</pre>
<div class="block">Use the fastest DCT/IDCT algorithm available in the underlying codec.  The
 default if this flag is not specified is implementation-specific.  For
 example, the implementation of TurboJPEG for libjpeg[-turbo] uses the fast
 algorithm by default when compressing, because this has been shown to have
 only a very slight effect on accuracy, but it uses the accurate algorithm
 when decompressing, because this has been shown to have a larger effect.</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.FLAG_FASTDCT">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="FLAG_ACCURATEDCT">
<!--   -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>FLAG_ACCURATEDCT</h4>
<pre>public static final&nbsp;int FLAG_ACCURATEDCT</pre>
<div class="block">Use the most accurate DCT/IDCT algorithm available in the underlying
 codec.  The default if this flag is not specified is
 implementation-specific.  For example, the implementation of TurboJPEG for
 libjpeg[-turbo] uses the fast algorithm by default when compressing,
 because this has been shown to have only a very slight effect on accuracy,
 but it uses the accurate algorithm when decompressing, because this has
 been shown to have a larger effect.</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.FLAG_ACCURATEDCT">Constant Field Values</a></dd></dl>
</li>
</ul>
</li>
</ul>
<!-- ========= CONSTRUCTOR DETAIL ======== -->
<ul class="blockList">
<li class="blockList"><a name="constructor_detail">
<!--   -->
</a>
<h3>Constructor Detail</h3>
<a name="TJ()">
<!--   -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>TJ</h4>
<pre>public&nbsp;TJ()</pre>
</li>
</ul>
</li>
</ul>
<!-- ============ METHOD DETAIL ========== -->
<ul class="blockList">
<li class="blockList"><a name="method_detail">
<!--   -->
</a>
<h3>Method Detail</h3>
<a name="getMCUWidth(int)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getMCUWidth</h4>
<pre>public static&nbsp;int&nbsp;getMCUWidth(int&nbsp;subsamp)</pre>
<div class="block">Returns the MCU block width for the given level of chrominance
 subsampling.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>subsamp</code> - the level of chrominance subsampling (one of
 <code>SAMP_*</code>)</dd>
<dt><span class="strong">Returns:</span></dt><dd>the MCU block width for the given level of chrominance
 subsampling.</dd></dl>
</li>
</ul>
<a name="getMCUHeight(int)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getMCUHeight</h4>
<pre>public static&nbsp;int&nbsp;getMCUHeight(int&nbsp;subsamp)</pre>
<div class="block">Returns the MCU block height for the given level of chrominance
 subsampling.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>subsamp</code> - the level of chrominance subsampling (one of
 <code>SAMP_*</code>)</dd>
<dt><span class="strong">Returns:</span></dt><dd>the MCU block height for the given level of chrominance
 subsampling.</dd></dl>
</li>
</ul>
<a name="getPixelSize(int)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getPixelSize</h4>
<pre>public static&nbsp;int&nbsp;getPixelSize(int&nbsp;pixelFormat)</pre>
<div class="block">Returns the pixel size (in bytes) for the given pixel format.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>pixelFormat</code> - the pixel format (one of <code>PF_*</code>)</dd>
<dt><span class="strong">Returns:</span></dt><dd>the pixel size (in bytes) for the given pixel format.</dd></dl>
</li>
</ul>
<a name="getRedOffset(int)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getRedOffset</h4>
<pre>public static&nbsp;int&nbsp;getRedOffset(int&nbsp;pixelFormat)</pre>
<div class="block">For the given pixel format, returns the number of bytes that the red
 component is offset from the start of the pixel.  For instance, if a pixel
 of format <code>TJ.PF_BGRX</code> is stored in <code>char pixel[]</code>,
 then the red component will be
 <code>pixel[TJ.getRedOffset(TJ.PF_BGRX)]</code>.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>pixelFormat</code> - the pixel format (one of <code>PF_*</code>)</dd>
<dt><span class="strong">Returns:</span></dt><dd>the red offset for the given pixel format.</dd></dl>
</li>
</ul>
<a name="getGreenOffset(int)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getGreenOffset</h4>
<pre>public static&nbsp;int&nbsp;getGreenOffset(int&nbsp;pixelFormat)</pre>
<div class="block">For the given pixel format, returns the number of bytes that the green
 component is offset from the start of the pixel.  For instance, if a pixel
 of format <code>TJ.PF_BGRX</code> is stored in <code>char pixel[]</code>,
 then the green component will be
 <code>pixel[TJ.getGreenOffset(TJ.PF_BGRX)]</code>.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>pixelFormat</code> - the pixel format (one of <code>PF_*</code>)</dd>
<dt><span class="strong">Returns:</span></dt><dd>the green offset for the given pixel format.</dd></dl>
</li>
</ul>
<a name="getBlueOffset(int)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getBlueOffset</h4>
<pre>public static&nbsp;int&nbsp;getBlueOffset(int&nbsp;pixelFormat)</pre>
<div class="block">For the given pixel format, returns the number of bytes that the blue
 component is offset from the start of the pixel.  For instance, if a pixel
 of format <code>TJ.PF_BGRX</code> is stored in <code>char pixel[]</code>,
 then the blue component will be
 <code>pixel[TJ.getBlueOffset(TJ.PF_BGRX)]</code>.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>pixelFormat</code> - the pixel format (one of <code>PF_*</code>)</dd>
<dt><span class="strong">Returns:</span></dt><dd>the blue offset for the given pixel format.</dd></dl>
</li>
</ul>
<a name="bufSize(int, int, int)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>bufSize</h4>
<pre>public static&nbsp;int&nbsp;bufSize(int&nbsp;width,
          int&nbsp;height,
          int&nbsp;jpegSubsamp)</pre>
<div class="block">Returns the maximum size of the buffer (in bytes) required to hold a JPEG
 image with the given width, height, and level of chrominance subsampling.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>width</code> - the width (in pixels) of the JPEG image</dd><dd><code>height</code> - the height (in pixels) of the JPEG image</dd><dd><code>jpegSubsamp</code> - the level of chrominance subsampling to be used when
 generating the JPEG image (one of <a href="../../../org/libjpegturbo/turbojpeg/TJ.html" title="class in org.libjpegturbo.turbojpeg"><code>TJ.SAMP_*</code></a>)</dd>
<dt><span class="strong">Returns:</span></dt><dd>the maximum size of the buffer (in bytes) required to hold a JPEG
 image with the given width, height, and level of chrominance subsampling.</dd></dl>
</li>
</ul>
<a name="bufSizeYUV(int, int, int, int)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>bufSizeYUV</h4>
<pre>public static&nbsp;int&nbsp;bufSizeYUV(int&nbsp;width,
             int&nbsp;pad,
             int&nbsp;height,
             int&nbsp;subsamp)</pre>
<div class="block">Returns the size of the buffer (in bytes) required to hold a YUV planar
 image with the given width, height, and level of chrominance subsampling.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>width</code> - the width (in pixels) of the YUV image</dd><dd><code>pad</code> - the width of each line in each plane of the image is padded to
 the nearest multiple of this number of bytes (must be a power of 2.)</dd><dd><code>height</code> - the height (in pixels) of the YUV image</dd><dd><code>subsamp</code> - the level of chrominance subsampling used in the YUV
 image (one of <a href="../../../org/libjpegturbo/turbojpeg/TJ.html" title="class in org.libjpegturbo.turbojpeg"><code>TJ.SAMP_*</code></a>)</dd>
<dt><span class="strong">Returns:</span></dt><dd>the size of the buffer (in bytes) required to hold a YUV planar
 image with the given width, height, and level of chrominance subsampling.</dd></dl>
</li>
</ul>
<a name="bufSizeYUV(int, int, int)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>bufSizeYUV</h4>
<pre>@Deprecated
public static&nbsp;int&nbsp;bufSizeYUV(int&nbsp;width,
                        int&nbsp;height,
                        int&nbsp;subsamp)</pre>
<div class="block"><span class="strong">Deprecated.</span>&nbsp;<i>Use <a href="../../../org/libjpegturbo/turbojpeg/TJ.html#bufSizeYUV(int,%20int,%20int,%20int)"><code>bufSizeYUV(int, int, int, int)</code></a> instead.</i></div>
</li>
</ul>
<a name="planeSizeYUV(int, int, int, int, int)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>planeSizeYUV</h4>
<pre>public static&nbsp;int&nbsp;planeSizeYUV(int&nbsp;componentID,
               int&nbsp;width,
               int&nbsp;stride,
               int&nbsp;height,
               int&nbsp;subsamp)</pre>
<div class="block">Returns the size of the buffer (in bytes) required to hold a YUV image
 plane with the given parameters.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>componentID</code> - ID number of the image plane (0 = Y, 1 = U/Cb,
 2 = V/Cr)</dd><dd><code>width</code> - width (in pixels) of the YUV image.  NOTE: this is the width
 of the whole image, not the plane width.</dd><dd><code>stride</code> - bytes per line in the image plane.</dd><dd><code>height</code> - height (in pixels) of the YUV image.  NOTE: this is the
 height of the whole image, not the plane height.</dd><dd><code>subsamp</code> - the level of chrominance subsampling used in the YUV
 image (one of <a href="../../../org/libjpegturbo/turbojpeg/TJ.html" title="class in org.libjpegturbo.turbojpeg"><code>TJ.SAMP_*</code></a>)</dd>
<dt><span class="strong">Returns:</span></dt><dd>the size of the buffer (in bytes) required to hold a YUV planar
 image with the given parameters.</dd></dl>
</li>
</ul>
<a name="planeWidth(int, int, int)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>planeWidth</h4>
<pre>public static&nbsp;int&nbsp;planeWidth(int&nbsp;componentID,
             int&nbsp;width,
             int&nbsp;subsamp)</pre>
<div class="block">Returns the plane width of a YUV image plane with the given parameters.
 Refer to <a href="../../../org/libjpegturbo/turbojpeg/YUVImage.html" title="class in org.libjpegturbo.turbojpeg"><code>YUVImage</code></a> for a description of plane width.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>componentID</code> - ID number of the image plane (0 = Y, 1 = U/Cb,
 2 = V/Cr)</dd><dd><code>width</code> - width (in pixels) of the YUV image</dd><dd><code>subsamp</code> - the level of chrominance subsampling used in the YUV image
 (one of <a href="../../../org/libjpegturbo/turbojpeg/TJ.html" title="class in org.libjpegturbo.turbojpeg"><code>TJ.SAMP_*</code></a>)</dd>
<dt><span class="strong">Returns:</span></dt><dd>the plane width of a YUV image plane with the given parameters.</dd></dl>
</li>
</ul>
<a name="planeHeight(int, int, int)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>planeHeight</h4>
<pre>public static&nbsp;int&nbsp;planeHeight(int&nbsp;componentID,
              int&nbsp;height,
              int&nbsp;subsamp)</pre>
<div class="block">Returns the plane height of a YUV image plane with the given parameters.
 Refer to <a href="../../../org/libjpegturbo/turbojpeg/YUVImage.html" title="class in org.libjpegturbo.turbojpeg"><code>YUVImage</code></a> for a description of plane height.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>componentID</code> - ID number of the image plane (0 = Y, 1 = U/Cb,
 2 = V/Cr)</dd><dd><code>height</code> - height (in pixels) of the YUV image</dd><dd><code>subsamp</code> - the level of chrominance subsampling used in the YUV image
 (one of <a href="../../../org/libjpegturbo/turbojpeg/TJ.html" title="class in org.libjpegturbo.turbojpeg"><code>TJ.SAMP_*</code></a>)</dd>
<dt><span class="strong">Returns:</span></dt><dd>the plane height of a YUV image plane with the given parameters.</dd></dl>
</li>
</ul>
<a name="getScalingFactors()">
<!--   -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>getScalingFactors</h4>
<pre>public static&nbsp;<a href="../../../org/libjpegturbo/turbojpeg/TJScalingFactor.html" title="class in org.libjpegturbo.turbojpeg">TJScalingFactor</a>[]&nbsp;getScalingFactors()</pre>
<div class="block">Returns a list of fractional scaling factors that the JPEG decompressor in
 this implementation of TurboJPEG supports.</div>
<dl><dt><span class="strong">Returns:</span></dt><dd>a list of fractional scaling factors that the JPEG decompressor in
 this implementation of TurboJPEG supports.</dd></dl>
</li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
</div>
<!-- ========= END OF CLASS DATA ========= -->
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<div class="bottomNav"><a name="navbar_bottom">
<!--   -->
</a><a href="#skip-navbar_bottom" title="Skip navigation links"></a><a name="navbar_bottom_firstrow">
<!--   -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../org/libjpegturbo/turbojpeg/package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../index-all.html">Index</a></li>
<li><a href="../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li>Prev Class</li>
<li><a href="../../../org/libjpegturbo/turbojpeg/TJCompressor.html" title="class in org.libjpegturbo.turbojpeg"><span class="strong">Next Class</span></a></li>
</ul>
<ul class="navList">
<li><a href="../../../index.html?org/libjpegturbo/turbojpeg/TJ.html" target="_top">Frames</a></li>
<li><a href="TJ.html" target="_top">No Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_bottom">
<li><a href="../../../allclasses-noframe.html">All Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
  allClassesLink = document.getElementById("allclasses_navbar_bottom");
  if(window==top) {
    allClassesLink.style.display = "block";
  }
  else {
    allClassesLink.style.display = "none";
  }
  //-->
</script>
</div>
<div>
<ul class="subNavList">
<li>Summary:&nbsp;</li>
<li>Nested&nbsp;|&nbsp;</li>
<li><a href="#field_summary">Field</a>&nbsp;|&nbsp;</li>
<li><a href="#constructor_summary">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method_summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li><a href="#field_detail">Field</a>&nbsp;|&nbsp;</li>
<li><a href="#constructor_detail">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method_detail">Method</a></li>
</ul>
</div>
<a name="skip-navbar_bottom">
<!--   -->
</a></div>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
</body>
</html>