Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
dragonwell8_jdk
提交
7c832cd1
D
dragonwell8_jdk
项目概览
openanolis
/
dragonwell8_jdk
通知
4
Star
2
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
D
dragonwell8_jdk
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
7c832cd1
编写于
9月 30, 2013
作者:
V
vadim
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
8001119: [fingbugs] Evaluate necessity to make some arrays package protected
Reviewed-by: prr, bae
上级
78ab46ba
变更
8
隐藏空白更改
内联
并排
Showing
8 changed file
with
90 addition
and
68 deletion
+90
-68
src/share/classes/com/sun/imageio/plugins/bmp/BMPCompressionTypes.java
...sses/com/sun/imageio/plugins/bmp/BMPCompressionTypes.java
+47
-0
src/share/classes/com/sun/imageio/plugins/bmp/BMPConstants.java
...are/classes/com/sun/imageio/plugins/bmp/BMPConstants.java
+0
-3
src/share/classes/com/sun/imageio/plugins/bmp/BMPImageWriter.java
...e/classes/com/sun/imageio/plugins/bmp/BMPImageWriter.java
+22
-37
src/share/classes/com/sun/imageio/plugins/bmp/BMPMetadata.java
...hare/classes/com/sun/imageio/plugins/bmp/BMPMetadata.java
+1
-1
src/share/classes/com/sun/imageio/plugins/gif/GIFStreamMetadata.java
...lasses/com/sun/imageio/plugins/gif/GIFStreamMetadata.java
+2
-5
src/share/classes/com/sun/imageio/plugins/jpeg/JPEG.java
src/share/classes/com/sun/imageio/plugins/jpeg/JPEG.java
+5
-8
src/share/classes/com/sun/imageio/plugins/png/PNGMetadata.java
...hare/classes/com/sun/imageio/plugins/png/PNGMetadata.java
+11
-13
src/share/classes/javax/imageio/plugins/bmp/BMPImageWriteParam.java
...classes/javax/imageio/plugins/bmp/BMPImageWriteParam.java
+2
-1
未找到文件。
src/share/classes/com/sun/imageio/plugins/bmp/BMPCompressionTypes.java
0 → 100644
浏览文件 @
7c832cd1
/*
* Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation. Oracle designates this
* particular file as subject to the "Classpath" exception as provided
* by Oracle in the LICENSE file that accompanied this code.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
package
com.sun.imageio.plugins.bmp
;
public
class
BMPCompressionTypes
{
private
static
final
String
[]
compressionTypeNames
=
{
"BI_RGB"
,
"BI_RLE8"
,
"BI_RLE4"
,
"BI_BITFIELDS"
,
"BI_JPEG"
,
"BI_PNG"
};
static
int
getType
(
String
typeString
)
{
for
(
int
i
=
0
;
i
<
compressionTypeNames
.
length
;
i
++)
if
(
compressionTypeNames
[
i
].
equals
(
typeString
))
return
i
;
return
0
;
}
static
String
getName
(
int
type
)
{
return
compressionTypeNames
[
type
];
}
public
static
String
[]
getCompressionTypes
()
{
return
compressionTypeNames
.
clone
();
}
}
src/share/classes/com/sun/imageio/plugins/bmp/BMPConstants.java
浏览文件 @
7c832cd1
...
...
@@ -47,7 +47,4 @@ public interface BMPConstants {
static
final
int
BI_BITFIELDS
=
3
;
static
final
int
BI_JPEG
=
4
;
static
final
int
BI_PNG
=
5
;
static
final
String
[]
compressionTypeNames
=
{
"BI_RGB"
,
"BI_RLE8"
,
"BI_RLE4"
,
"BI_BITFIELDS"
,
"BI_JPEG"
,
"BI_PNG"
};
}
src/share/classes/com/sun/imageio/plugins/bmp/BMPImageWriter.java
浏览文件 @
7c832cd1
...
...
@@ -25,7 +25,6 @@
package
com.sun.imageio.plugins.bmp
;
import
java.awt.Point
;
import
java.awt.Rectangle
;
import
java.awt.image.ColorModel
;
import
java.awt.image.ComponentSampleModel
;
...
...
@@ -42,7 +41,6 @@ import java.awt.image.Raster;
import
java.awt.image.RenderedImage
;
import
java.awt.image.SampleModel
;
import
java.awt.image.SinglePixelPackedSampleModel
;
import
java.awt.image.WritableRaster
;
import
java.awt.image.BufferedImage
;
import
java.io.IOException
;
...
...
@@ -51,22 +49,16 @@ import java.nio.ByteOrder;
import
java.util.Iterator
;
import
javax.imageio.IIOImage
;
import
javax.imageio.IIOException
;
import
javax.imageio.ImageIO
;
import
javax.imageio.ImageTypeSpecifier
;
import
javax.imageio.ImageWriteParam
;
import
javax.imageio.ImageWriter
;
import
javax.imageio.metadata.IIOMetadata
;
import
javax.imageio.metadata.IIOMetadataNode
;
import
javax.imageio.metadata.IIOMetadataFormatImpl
;
import
javax.imageio.metadata.IIOInvalidTreeException
;
import
javax.imageio.spi.ImageWriterSpi
;
import
javax.imageio.stream.ImageOutputStream
;
import
javax.imageio.event.IIOWriteProgressListener
;
import
javax.imageio.event.IIOWriteWarningListener
;
import
org.w3c.dom.Node
;
import
org.w3c.dom.NodeList
;
import
javax.imageio.plugins.bmp.BMPImageWriteParam
;
import
com.sun.imageio.plugins.common.ImageUtil
;
...
...
@@ -129,7 +121,7 @@ public class BMPImageWriter extends ImageWriter implements BMPConstants {
meta
.
compression
=
getPreferredCompressionType
(
imageType
);
if
(
param
!=
null
&&
param
.
getCompressionMode
()
==
ImageWriteParam
.
MODE_EXPLICIT
)
{
meta
.
compression
=
getCompression
Type
(
param
.
getCompressionType
());
meta
.
compression
=
BMPCompressionTypes
.
get
Type
(
param
.
getCompressionType
());
}
meta
.
bitsPerPixel
=
(
short
)
imageType
.
getColorModel
().
getPixelSize
();
return
meta
;
...
...
@@ -308,7 +300,7 @@ public class BMPImageWriter extends ImageWriter implements BMPConstants {
switch
(
bmpParam
.
getCompressionMode
())
{
case
ImageWriteParam
.
MODE_EXPLICIT
:
compressionType
=
getCompression
Type
(
bmpParam
.
getCompressionType
());
compressionType
=
BMPCompressionTypes
.
get
Type
(
bmpParam
.
getCompressionType
());
break
;
case
ImageWriteParam
.
MODE_COPY_FROM_METADATA
:
compressionType
=
bmpImageMetadata
.
compression
;
...
...
@@ -323,12 +315,12 @@ public class BMPImageWriter extends ImageWriter implements BMPConstants {
if
(!
canEncodeImage
(
compressionType
,
colorModel
,
sampleModel
))
{
throw
new
IOException
(
"Image can not be encoded with compression type "
+
compressionTypeNames
[
compressionType
]
);
+
BMPCompressionTypes
.
getName
(
compressionType
)
);
}
byte
r
[]
=
null
,
g
[]
=
null
,
b
[]
=
null
,
a
[]
=
null
;
if
(
compressionType
==
B
MPConstants
.
B
I_BITFIELDS
)
{
if
(
compressionType
==
BI_BITFIELDS
)
{
bitsPerPixel
=
DataBuffer
.
getDataTypeSize
(
sampleModel
.
getDataType
());
...
...
@@ -372,7 +364,7 @@ public class BMPImageWriter extends ImageWriter implements BMPConstants {
// an exception related to unsupported image format
throw
new
IOException
(
"Image can not be encoded with "
+
"compression type "
+
compressionTypeNames
[
compressionType
]
);
BMPCompressionTypes
.
getName
(
compressionType
)
);
}
}
writeMaskToPalette
(
rmask
,
0
,
r
,
g
,
b
,
a
);
...
...
@@ -511,8 +503,8 @@ public class BMPImageWriter extends ImageWriter implements BMPConstants {
* Images with any other compression type must be wrote in the
* bottom-up layout.
*/
if
(
compressionType
==
B
MPConstants
.
B
I_RGB
||
compressionType
==
B
MPConstants
.
B
I_BITFIELDS
)
if
(
compressionType
==
BI_RGB
||
compressionType
==
BI_BITFIELDS
)
{
isTopDown
=
bmpParam
.
isTopDown
();
}
else
{
...
...
@@ -543,7 +535,7 @@ public class BMPImageWriter extends ImageWriter implements BMPConstants {
if
(
isPalette
==
true
)
{
// write palette
if
(
compressionType
==
B
MPConstants
.
B
I_BITFIELDS
)
{
if
(
compressionType
==
BI_BITFIELDS
)
{
// write masks for red, green and blue components.
for
(
int
i
=
0
;
i
<
3
;
i
++)
{
int
mask
=
(
a
[
i
]&
0xFF
)
+
((
r
[
i
]&
0xFF
)*
0x100
)
+
((
g
[
i
]&
0xFF
)*
0x10000
)
+
((
b
[
i
]&
0xFF
)*
0x1000000
);
...
...
@@ -571,8 +563,8 @@ public class BMPImageWriter extends ImageWriter implements BMPConstants {
int
l
;
if
(
compressionType
==
B
MPConstants
.
B
I_JPEG
||
compressionType
==
B
MPConstants
.
B
I_PNG
)
{
if
(
compressionType
==
BI_JPEG
||
compressionType
==
BI_PNG
)
{
// prepare embedded buffer
embedded_stream
=
new
ByteArrayOutputStream
();
...
...
@@ -657,7 +649,7 @@ public class BMPImageWriter extends ImageWriter implements BMPConstants {
pos
=
sppsm
.
getOffset
(
startX
,
startY
);
}
if
(
compressionType
==
B
MPConstants
.
BI_RGB
||
compressionType
==
BMPConstants
.
BI_BITFIELDS
){
if
(
compressionType
==
B
I_RGB
||
compressionType
==
BI_BITFIELDS
){
switch
(
dataType
)
{
case
DataBuffer
.
TYPE_BYTE
:
byte
[]
bdata
=
...
...
@@ -687,7 +679,7 @@ public class BMPImageWriter extends ImageWriter implements BMPConstants {
for
(
int
k
=
0
;
k
<
padding
;
k
++)
{
stream
.
writeByte
(
0
);
}
}
else
if
(
compressionType
==
B
MPConstants
.
B
I_RLE4
)
{
}
else
if
(
compressionType
==
BI_RLE4
)
{
if
(
bpixels
==
null
||
bpixels
.
length
<
scanlineBytes
)
bpixels
=
new
byte
[
scanlineBytes
];
src
.
getPixels
(
srcRect
.
x
,
srcRect
.
y
,
...
...
@@ -696,7 +688,7 @@ public class BMPImageWriter extends ImageWriter implements BMPConstants {
bpixels
[
h
]
=
(
byte
)
pixels
[
h
];
}
encodeRLE4
(
bpixels
,
scanlineBytes
);
}
else
if
(
compressionType
==
B
MPConstants
.
B
I_RLE8
)
{
}
else
if
(
compressionType
==
BI_RLE8
)
{
//byte[] bdata =
// ((DataBufferByte)src.getDataBuffer()).getData();
//System.out.println("bdata.length="+bdata.length);
...
...
@@ -734,8 +726,8 @@ public class BMPImageWriter extends ImageWriter implements BMPConstants {
processImageProgress
(
100.0f
*
(((
float
)
i
)
/
((
float
)
h
)));
}
if
(
compressionType
==
B
MPConstants
.
B
I_RLE4
||
compressionType
==
B
MPConstants
.
B
I_RLE8
)
{
if
(
compressionType
==
BI_RLE4
||
compressionType
==
BI_RLE8
)
{
// Write the RLE EOF marker and
stream
.
writeByte
(
0
);
stream
.
writeByte
(
1
);
...
...
@@ -793,7 +785,7 @@ public class BMPImageWriter extends ImageWriter implements BMPConstants {
break
;
case
4
:
if
(
compressionType
==
B
MPConstants
.
B
I_RLE4
){
if
(
compressionType
==
BI_RLE4
){
byte
[]
bipixels
=
new
byte
[
scanlineBytes
];
for
(
int
h
=
0
;
h
<
scanlineBytes
;
h
++)
{
bipixels
[
h
]
=
(
byte
)
pixels
[
l
++];
...
...
@@ -814,7 +806,7 @@ public class BMPImageWriter extends ImageWriter implements BMPConstants {
break
;
case
8
:
if
(
compressionType
==
B
MPConstants
.
B
I_RLE8
)
{
if
(
compressionType
==
BI_RLE8
)
{
for
(
int
h
=
0
;
h
<
scanlineBytes
;
h
++)
{
bpixels
[
h
]
=
(
byte
)
pixels
[
l
++];
}
...
...
@@ -841,7 +833,7 @@ public class BMPImageWriter extends ImageWriter implements BMPConstants {
*/
for
(
int
j
=
0
,
m
=
0
;
j
<
scanlineBytes
;
m
++)
{
spixels
[
m
]
=
0
;
if
(
compressionType
==
B
MPConstants
.
B
I_RGB
)
{
if
(
compressionType
==
BI_RGB
)
{
/*
* please note that despite other cases,
* the 16bpp BI_RGB requires the RGB data order
...
...
@@ -910,7 +902,7 @@ public class BMPImageWriter extends ImageWriter implements BMPConstants {
*/
for
(
int
j
=
0
,
m
=
0
;
j
<
scanlineBytes
;
m
++)
{
ipixels
[
m
]
=
0
;
if
(
compressionType
==
B
MPConstants
.
B
I_RGB
)
{
if
(
compressionType
==
BI_RGB
)
{
ipixels
[
m
]
=
((
0xff
&
pixels
[
j
+
2
])
<<
16
)
|
((
0xff
&
pixels
[
j
+
1
])
<<
8
)
|
...
...
@@ -945,8 +937,8 @@ public class BMPImageWriter extends ImageWriter implements BMPConstants {
}
// Write out the padding
if
(
compressionType
==
B
MPConstants
.
B
I_RGB
||
compressionType
==
B
MPConstants
.
B
I_BITFIELDS
)
if
(
compressionType
==
BI_RGB
||
compressionType
==
BI_BITFIELDS
)
{
for
(
k
=
0
;
k
<
padding
;
k
++)
{
stream
.
writeByte
(
0
);
...
...
@@ -1329,17 +1321,10 @@ public class BMPImageWriter extends ImageWriter implements BMPConstants {
stream
=
null
;
}
private
int
getCompressionType
(
String
typeString
)
{
for
(
int
i
=
0
;
i
<
BMPConstants
.
compressionTypeNames
.
length
;
i
++)
if
(
BMPConstants
.
compressionTypeNames
[
i
].
equals
(
typeString
))
return
i
;
return
0
;
}
private
void
writeEmbedded
(
IIOImage
image
,
ImageWriteParam
bmpParam
)
throws
IOException
{
String
format
=
compressionType
==
B
MPConstants
.
B
I_JPEG
?
"jpeg"
:
"png"
;
compressionType
==
BI_JPEG
?
"jpeg"
:
"png"
;
Iterator
iterator
=
ImageIO
.
getImageWritersByFormatName
(
format
);
ImageWriter
writer
=
null
;
if
(
iterator
.
hasNext
())
...
...
src/share/classes/com/sun/imageio/plugins/bmp/BMPMetadata.java
浏览文件 @
7c832cd1
...
...
@@ -219,7 +219,7 @@ public class BMPMetadata extends IIOMetadata implements BMPConstants {
// CompressionTypeName
IIOMetadataNode
subNode
=
new
IIOMetadataNode
(
"CompressionTypeName"
);
subNode
.
setAttribute
(
"value"
,
compressionTypeNames
[
compression
]
);
subNode
.
setAttribute
(
"value"
,
BMPCompressionTypes
.
getName
(
compression
)
);
node
.
appendChild
(
subNode
);
return
node
;
}
...
...
src/share/classes/com/sun/imageio/plugins/gif/GIFStreamMetadata.java
浏览文件 @
7c832cd1
...
...
@@ -25,11 +25,8 @@
package
com.sun.imageio.plugins.gif
;
import
javax.imageio.ImageTypeSpecifier
;
import
javax.imageio.metadata.IIOInvalidTreeException
;
import
javax.imageio.metadata.IIOMetadata
;
import
javax.imageio.metadata.IIOMetadataNode
;
import
javax.imageio.metadata.IIOMetadataFormat
;
import
javax.imageio.metadata.IIOMetadataFormatImpl
;
import
org.w3c.dom.Node
;
...
...
@@ -41,7 +38,7 @@ public class GIFStreamMetadata extends GIFMetadata {
static
final
String
nativeMetadataFormatName
=
"javax_imageio_gif_stream_1.0"
;
public
static
final
String
[]
versionStrings
=
{
"87a"
,
"89a"
};
static
final
String
[]
versionStrings
=
{
"87a"
,
"89a"
};
public
String
version
;
// 87a or 89a
public
int
logicalScreenWidth
;
...
...
@@ -52,7 +49,7 @@ public class GIFStreamMetadata extends GIFMetadata {
public
int
backgroundColorIndex
;
// Valid if globalColorTable != null
public
boolean
sortFlag
;
// Valid if globalColorTable != null
public
static
final
String
[]
colorTableSizes
=
{
static
final
String
[]
colorTableSizes
=
{
"2"
,
"4"
,
"8"
,
"16"
,
"32"
,
"64"
,
"128"
,
"256"
};
...
...
src/share/classes/com/sun/imageio/plugins/jpeg/JPEG.java
浏览文件 @
7c832cd1
...
...
@@ -25,14 +25,11 @@
package
com.sun.imageio.plugins.jpeg
;
import
javax.imageio.metadata.IIOMetadataFormatImpl
;
import
javax.imageio.ImageTypeSpecifier
;
import
javax.imageio.plugins.jpeg.JPEGQTable
;
import
javax.imageio.plugins.jpeg.JPEGHuffmanTable
;
import
java.awt.image.ColorModel
;
import
java.awt.image.BufferedImage
;
import
java.awt.image.DataBuffer
;
import
java.awt.color.ColorSpace
;
import
java.awt.color.ICC_ColorSpace
;
...
...
@@ -172,9 +169,9 @@ public class JPEG {
public
static
final
String
vendor
=
"Oracle Corporation"
;
public
static
final
String
version
=
"0.5"
;
// Names of the formats we can read or write
public
static
final
String
[]
names
=
{
"JPEG"
,
"jpeg"
,
"JPG"
,
"jpg"
};
public
static
final
String
[]
suffixes
=
{
"jpg"
,
"jpeg"
};
public
static
final
String
[]
MIMETypes
=
{
"image/jpeg"
};
static
final
String
[]
names
=
{
"JPEG"
,
"jpeg"
,
"JPG"
,
"jpg"
};
static
final
String
[]
suffixes
=
{
"jpg"
,
"jpeg"
};
static
final
String
[]
MIMETypes
=
{
"image/jpeg"
};
public
static
final
String
nativeImageMetadataFormatName
=
"javax_imageio_jpeg_image_1.0"
;
public
static
final
String
nativeImageMetadataFormatClassName
=
...
...
@@ -201,12 +198,12 @@ public class JPEG {
public
static
final
int
NUM_JCS_CODES
=
JCS_YCCK
+
1
;
/** IJG can handle up to 4-channel JPEGs */
public
static
final
int
[]
[]
bandOffsets
=
{{
0
},
static
final
int
[]
[]
bandOffsets
=
{{
0
},
{
0
,
1
},
{
0
,
1
,
2
},
{
0
,
1
,
2
,
3
}};
public
static
final
int
[]
bOffsRGB
=
{
2
,
1
,
0
};
static
final
int
[]
bOffsRGB
=
{
2
,
1
,
0
};
/* These are kept in the inner class to avoid static initialization
* of the CMM class until someone actually needs it.
...
...
src/share/classes/com/sun/imageio/plugins/png/PNGMetadata.java
浏览文件 @
7c832cd1
...
...
@@ -29,12 +29,10 @@ import java.awt.image.ColorModel;
import
java.awt.image.IndexColorModel
;
import
java.awt.image.SampleModel
;
import
java.util.ArrayList
;
import
java.util.Iterator
;
import
java.util.StringTokenizer
;
import
javax.imageio.ImageTypeSpecifier
;
import
javax.imageio.metadata.IIOInvalidTreeException
;
import
javax.imageio.metadata.IIOMetadata
;
import
javax.imageio.metadata.IIOMetadataFormat
;
import
javax.imageio.metadata.IIOMetadataFormatImpl
;
import
javax.imageio.metadata.IIOMetadataNode
;
import
org.w3c.dom.Node
;
...
...
@@ -49,42 +47,42 @@ public class PNGMetadata extends IIOMetadata implements Cloneable {
=
"com.sun.imageio.plugins.png.PNGMetadataFormat"
;
// Color types for IHDR chunk
public
static
final
String
[]
IHDR_colorTypeNames
=
{
static
final
String
[]
IHDR_colorTypeNames
=
{
"Grayscale"
,
null
,
"RGB"
,
"Palette"
,
"GrayAlpha"
,
null
,
"RGBAlpha"
};
public
static
final
int
[]
IHDR_numChannels
=
{
static
final
int
[]
IHDR_numChannels
=
{
1
,
0
,
3
,
3
,
2
,
0
,
4
};
// Bit depths for IHDR chunk
public
static
final
String
[]
IHDR_bitDepths
=
{
static
final
String
[]
IHDR_bitDepths
=
{
"1"
,
"2"
,
"4"
,
"8"
,
"16"
};
// Compression methods for IHDR chunk
public
static
final
String
[]
IHDR_compressionMethodNames
=
{
static
final
String
[]
IHDR_compressionMethodNames
=
{
"deflate"
};
// Filter methods for IHDR chunk
public
static
final
String
[]
IHDR_filterMethodNames
=
{
static
final
String
[]
IHDR_filterMethodNames
=
{
"adaptive"
};
// Interlace methods for IHDR chunk
public
static
final
String
[]
IHDR_interlaceMethodNames
=
{
static
final
String
[]
IHDR_interlaceMethodNames
=
{
"none"
,
"adam7"
};
// Compression methods for iCCP chunk
public
static
final
String
[]
iCCP_compressionMethodNames
=
{
static
final
String
[]
iCCP_compressionMethodNames
=
{
"deflate"
};
// Compression methods for zTXt chunk
public
static
final
String
[]
zTXt_compressionMethodNames
=
{
static
final
String
[]
zTXt_compressionMethodNames
=
{
"deflate"
};
...
...
@@ -95,12 +93,12 @@ public class PNGMetadata extends IIOMetadata implements Cloneable {
public
static
final
int
PHYS_UNIT_METER
=
1
;
// Unit specifiers for pHYs chunk
public
static
final
String
[]
unitSpecifierNames
=
{
static
final
String
[]
unitSpecifierNames
=
{
"unknown"
,
"meter"
};
// Rendering intents for sRGB chunk
public
static
final
String
[]
renderingIntentNames
=
{
static
final
String
[]
renderingIntentNames
=
{
"Perceptual"
,
// 0
"Relative colorimetric"
,
// 1
"Saturation"
,
// 2
...
...
@@ -109,7 +107,7 @@ public class PNGMetadata extends IIOMetadata implements Cloneable {
};
// Color space types for Chroma->ColorSpaceType node
public
static
final
String
[]
colorSpaceTypeNames
=
{
static
final
String
[]
colorSpaceTypeNames
=
{
"GRAY"
,
null
,
"RGB"
,
"RGB"
,
"GRAY"
,
null
,
"RGB"
};
...
...
src/share/classes/javax/imageio/plugins/bmp/BMPImageWriteParam.java
浏览文件 @
7c832cd1
...
...
@@ -29,6 +29,7 @@ import java.util.Locale;
import
javax.imageio.ImageWriteParam
;
import
com.sun.imageio.plugins.bmp.BMPConstants
;
import
com.sun.imageio.plugins.bmp.BMPCompressionTypes
;
/**
* A subclass of <code>ImageWriteParam</code> for encoding images in
...
...
@@ -78,7 +79,7 @@ public class BMPImageWriteParam extends ImageWriteParam {
super
(
locale
);
// Set compression types ("BI_RGB" denotes uncompressed).
compressionTypes
=
BMPCo
nstants
.
compressionTypeNames
.
clone
();
compressionTypes
=
BMPCo
mpressionTypes
.
getCompressionTypes
();
// Set compression flag.
canWriteCompressed
=
true
;
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录