mirror of
https://github.com/haraldk/TwelveMonkeys.git
synced 2025-08-04 20:15:28 -04:00
New SPI info.
This commit is contained in:
parent
26475eb004
commit
b40d4dad17
@ -28,8 +28,7 @@
|
||||
|
||||
package com.twelvemonkeys.imageio.plugins.bmp;
|
||||
|
||||
import com.twelvemonkeys.imageio.spi.ProviderInfo;
|
||||
import com.twelvemonkeys.imageio.util.IIOUtil;
|
||||
import com.twelvemonkeys.imageio.spi.ImageReaderSpiBase;
|
||||
|
||||
import javax.imageio.ImageReader;
|
||||
import javax.imageio.spi.ImageReaderSpi;
|
||||
@ -47,30 +46,9 @@ import java.util.Locale;
|
||||
* @author <a href="mailto:harald.kuhr@gmail.com">Harald Kuhr</a>
|
||||
* @version $Id: BMPImageReaderSpi.java,v 1.0 25.feb.2006 00:29:44 haku Exp$
|
||||
*/
|
||||
public final class BMPImageReaderSpi extends ImageReaderSpi {
|
||||
public final class BMPImageReaderSpi extends ImageReaderSpiBase {
|
||||
public BMPImageReaderSpi() {
|
||||
this(IIOUtil.getProviderInfo(BMPImageReaderSpi.class));
|
||||
}
|
||||
|
||||
private BMPImageReaderSpi(final ProviderInfo pProviderInfo) {
|
||||
super(
|
||||
pProviderInfo.getVendorName(),
|
||||
pProviderInfo.getVersion(),
|
||||
new String[]{"bmp", "BMP"},
|
||||
new String[]{"bmp", "rle"},
|
||||
new String[]{
|
||||
"image/bmp",
|
||||
"image/x-bmp"
|
||||
// "image/vnd.microsoft.bitmap", // TODO: Official IANA MIME
|
||||
},
|
||||
"com.twelvemonkeys.imageio.plugins.bmp.BMPImageReader",
|
||||
new Class[]{ImageInputStream.class},
|
||||
new String[]{"com.sun.imageio.plugins.bmp.BMPImageWriterSpi"}, // We support the same native metadata format
|
||||
false, null, null, null, null,
|
||||
true,
|
||||
BMPMetadata.nativeMetadataFormatName, "com.sun.imageio.plugins.bmp.BMPMetadataFormat",
|
||||
null, null
|
||||
);
|
||||
super(new BMPProviderInfo());
|
||||
}
|
||||
|
||||
static ImageReaderSpi lookupDefaultProvider(final ServiceRegistry registry) {
|
||||
|
@ -0,0 +1,31 @@
|
||||
package com.twelvemonkeys.imageio.plugins.bmp;
|
||||
|
||||
import com.twelvemonkeys.imageio.spi.ReaderWriterProviderInfo;
|
||||
|
||||
/**
|
||||
* BMPProviderInfo.
|
||||
*
|
||||
* @author <a href="mailto:harald.kuhr@gmail.com">Harald Kuhr</a>
|
||||
* @author last modified by $Author: harald.kuhr$
|
||||
* @version $Id: BMPProviderInfo.java,v 1.0 20/03/15 harald.kuhr Exp$
|
||||
*/
|
||||
final class BMPProviderInfo extends ReaderWriterProviderInfo {
|
||||
protected BMPProviderInfo() {
|
||||
super(
|
||||
BMPProviderInfo.class,
|
||||
new String[] {"bmp", "BMP"},
|
||||
new String[] {"bmp", "rle"},
|
||||
new String[] {
|
||||
"image/bmp",
|
||||
"image/x-bmp"
|
||||
// "image/vnd.microsoft.bitmap", // TODO: Official IANA MIME
|
||||
},
|
||||
"com.twelvemonkeys.imageio.plugins.bmp.BMPImageReader",
|
||||
new String[] {"com.twelvemonkeys.imageio.plugins.bmp.BMPImageReaderSpi"},
|
||||
"com.sun.imageio.plugins.bmp.BMPImageWriter",
|
||||
new String[]{"com.sun.imageio.plugins.bmp.BMPImageWriterSpi"}, // We support the same native metadata format
|
||||
false, null, null, null, null,
|
||||
true, BMPMetadata.nativeMetadataFormatName, "com.sun.imageio.plugins.bmp.BMPMetadataFormat", null, null
|
||||
);
|
||||
}
|
||||
}
|
@ -28,11 +28,9 @@
|
||||
|
||||
package com.twelvemonkeys.imageio.plugins.bmp;
|
||||
|
||||
import com.twelvemonkeys.imageio.spi.ProviderInfo;
|
||||
import com.twelvemonkeys.imageio.util.IIOUtil;
|
||||
import com.twelvemonkeys.imageio.spi.ImageReaderSpiBase;
|
||||
|
||||
import javax.imageio.ImageReader;
|
||||
import javax.imageio.spi.ImageReaderSpi;
|
||||
import javax.imageio.stream.ImageInputStream;
|
||||
import java.io.IOException;
|
||||
import java.util.Locale;
|
||||
@ -43,31 +41,10 @@ import java.util.Locale;
|
||||
* @author <a href="mailto:harald.kuhr@gmail.com">Harald Kuhr</a>
|
||||
* @version $Id: CURImageReaderSpi.java,v 1.0 25.feb.2006 00:29:44 haku Exp$
|
||||
*/
|
||||
public final class CURImageReaderSpi extends ImageReaderSpi {
|
||||
public final class CURImageReaderSpi extends ImageReaderSpiBase {
|
||||
|
||||
public CURImageReaderSpi() {
|
||||
this(IIOUtil.getProviderInfo(CURImageReaderSpi.class));
|
||||
}
|
||||
|
||||
private CURImageReaderSpi(final ProviderInfo pProviderInfo) {
|
||||
super(
|
||||
pProviderInfo.getVendorName(),
|
||||
pProviderInfo.getVersion(),
|
||||
new String[]{"cur", "CUR"},
|
||||
new String[]{"cur"},
|
||||
new String[]{
|
||||
"image/vnd.microsoft.cursor", // Official IANA MIME
|
||||
"image/x-cursor", // Common extension MIME
|
||||
"image/cursor" // Unofficial, but common
|
||||
},
|
||||
"com.twelvemonkeys.imageio.plugins.bmp.CURImageReader",
|
||||
new Class[] {ImageInputStream.class},
|
||||
null,
|
||||
true, null, null, null, null,
|
||||
true,
|
||||
null, null,
|
||||
null, null
|
||||
);
|
||||
super(new CURProviderInfo());
|
||||
}
|
||||
|
||||
public boolean canDecodeInput(final Object pSource) throws IOException {
|
||||
|
@ -0,0 +1,30 @@
|
||||
package com.twelvemonkeys.imageio.plugins.bmp;
|
||||
|
||||
import com.twelvemonkeys.imageio.spi.ReaderWriterProviderInfo;
|
||||
|
||||
/**
|
||||
* CURProviderInfo.
|
||||
*
|
||||
* @author <a href="mailto:harald.kuhr@gmail.com">Harald Kuhr</a>
|
||||
* @author last modified by $Author: harald.kuhr$
|
||||
* @version $Id: CURProviderInfo.java,v 1.0 20/03/15 harald.kuhr Exp$
|
||||
*/
|
||||
final class CURProviderInfo extends ReaderWriterProviderInfo {
|
||||
protected CURProviderInfo() {
|
||||
super(
|
||||
CURProviderInfo.class,
|
||||
new String[]{"cur", "CUR"},
|
||||
new String[]{"cur"},
|
||||
new String[]{
|
||||
"image/vnd.microsoft.cursor", // Official IANA MIME
|
||||
"image/x-cursor", // Common extension MIME
|
||||
"image/cursor" // Unofficial, but common
|
||||
},
|
||||
"com.twelvemonkeys.imageio.plugins.bmp.CURImageReader",
|
||||
new String[] {"com.twelvemonkeys.imageio.plugins.bmp.CURImageReaderSpi"},
|
||||
null, null,
|
||||
false, null, null, null, null,
|
||||
true, null, null, null, null
|
||||
);
|
||||
}
|
||||
}
|
@ -28,11 +28,9 @@
|
||||
|
||||
package com.twelvemonkeys.imageio.plugins.bmp;
|
||||
|
||||
import com.twelvemonkeys.imageio.spi.ProviderInfo;
|
||||
import com.twelvemonkeys.imageio.util.IIOUtil;
|
||||
import com.twelvemonkeys.imageio.spi.ImageReaderSpiBase;
|
||||
|
||||
import javax.imageio.ImageReader;
|
||||
import javax.imageio.spi.ImageReaderSpi;
|
||||
import javax.imageio.stream.ImageInputStream;
|
||||
import java.io.IOException;
|
||||
import java.util.Locale;
|
||||
@ -43,31 +41,10 @@ import java.util.Locale;
|
||||
* @author <a href="mailto:harald.kuhr@gmail.com">Harald Kuhr</a>
|
||||
* @version $Id: ICOImageReaderSpi.java,v 1.0 25.feb.2006 00:29:44 haku Exp$
|
||||
*/
|
||||
public final class ICOImageReaderSpi extends ImageReaderSpi {
|
||||
public final class ICOImageReaderSpi extends ImageReaderSpiBase {
|
||||
|
||||
public ICOImageReaderSpi() {
|
||||
this(IIOUtil.getProviderInfo(ICOImageReaderSpi.class));
|
||||
}
|
||||
|
||||
private ICOImageReaderSpi(final ProviderInfo pProviderInfo) {
|
||||
super(
|
||||
pProviderInfo.getVendorName(),
|
||||
pProviderInfo.getVersion(),
|
||||
new String[]{"ico", "ICO"},
|
||||
new String[]{"ico"},
|
||||
new String[]{
|
||||
"image/vnd.microsoft.icon", // Official IANA MIME
|
||||
"image/x-icon", // Common extension MIME
|
||||
"image/ico" // Unofficial, but common
|
||||
},
|
||||
"com.twelvemonkeys.imageio.plugins.bmp.ICOImageReader",
|
||||
new Class[] {ImageInputStream.class},
|
||||
null,
|
||||
true, null, null, null, null,
|
||||
true,
|
||||
null, null,
|
||||
null, null
|
||||
);
|
||||
super(new ICOProviderInfo());
|
||||
}
|
||||
|
||||
public boolean canDecodeInput(final Object pSource) throws IOException {
|
||||
|
@ -0,0 +1,30 @@
|
||||
package com.twelvemonkeys.imageio.plugins.bmp;
|
||||
|
||||
import com.twelvemonkeys.imageio.spi.ReaderWriterProviderInfo;
|
||||
|
||||
/**
|
||||
* CURProviderInfo.
|
||||
*
|
||||
* @author <a href="mailto:harald.kuhr@gmail.com">Harald Kuhr</a>
|
||||
* @author last modified by $Author: harald.kuhr$
|
||||
* @version $Id: CURProviderInfo.java,v 1.0 20/03/15 harald.kuhr Exp$
|
||||
*/
|
||||
final class ICOProviderInfo extends ReaderWriterProviderInfo {
|
||||
protected ICOProviderInfo() {
|
||||
super(
|
||||
ICOProviderInfo.class,
|
||||
new String[]{"ico", "ICO"},
|
||||
new String[]{"ico"},
|
||||
new String[]{
|
||||
"image/vnd.microsoft.icon", // Official IANA MIME
|
||||
"image/x-icon", // Common extension MIME
|
||||
"image/ico" // Unofficial, but common
|
||||
},
|
||||
"com.twelvemonkeys.imageio.plugins.bmp.ICOImageReader",
|
||||
new String[] {"com.twelvemonkeys.imageio.plugins.bmp.ICOImageReaderSpi"},
|
||||
null, null,
|
||||
false, null, null, null, null,
|
||||
true, null, null, null, null
|
||||
);
|
||||
}
|
||||
}
|
@ -0,0 +1,27 @@
|
||||
package com.twelvemonkeys.imageio.spi;
|
||||
|
||||
import javax.imageio.spi.ImageReaderSpi;
|
||||
|
||||
/**
|
||||
* ImageReaderSpiBase.
|
||||
*
|
||||
* @author <a href="mailto:harald.kuhr@gmail.com">Harald Kuhr</a>
|
||||
* @author last modified by $Author: harald.kuhr$
|
||||
* @version $Id: ImageReaderSpiBase.java,v 1.0 20/03/15 harald.kuhr Exp$
|
||||
*/
|
||||
public abstract class ImageReaderSpiBase extends ImageReaderSpi {
|
||||
protected ImageReaderSpiBase(final ReaderWriterProviderInfo info) {
|
||||
super(
|
||||
info.getVendorName(), info.getVersion(),
|
||||
info.formatNames(), info.suffixes(), info.mimeTypes(),
|
||||
info.readerClassName(), info.inputTypes(),
|
||||
info.writerSpiClassNames(),
|
||||
info.supportsStandardStreamMetadataFormat(),
|
||||
info.nativeStreamMetadataFormatName(), info.nativeStreamMetadataFormatClassName(),
|
||||
info.extraStreamMetadataFormatNames(), info.extraStreamMetadataFormatClassNames(),
|
||||
info.supportsStandardImageMetadataFormat(),
|
||||
info.nativeImageMetadataFormatName(), info.nativeImageMetadataFormatClassName(),
|
||||
info.extraImageMetadataFormatNames(), info.extraImageMetadataFormatClassNames()
|
||||
);
|
||||
}
|
||||
}
|
@ -0,0 +1,27 @@
|
||||
package com.twelvemonkeys.imageio.spi;
|
||||
|
||||
import javax.imageio.spi.ImageWriterSpi;
|
||||
|
||||
/**
|
||||
* ImageWriterSpiBase.
|
||||
*
|
||||
* @author <a href="mailto:harald.kuhr@gmail.com">Harald Kuhr</a>
|
||||
* @author last modified by $Author: harald.kuhr$
|
||||
* @version $Id: ImageWriterSpiBase.java,v 1.0 20/03/15 harald.kuhr Exp$
|
||||
*/
|
||||
public abstract class ImageWriterSpiBase extends ImageWriterSpi {
|
||||
protected ImageWriterSpiBase(final ReaderWriterProviderInfo info) {
|
||||
super(
|
||||
info.getVendorName(), info.getVersion(),
|
||||
info.formatNames(), info.suffixes(), info.mimeTypes(),
|
||||
info.writerClassName(), info.outputTypes(),
|
||||
info.readerSpiClassNames(),
|
||||
info.supportsStandardStreamMetadataFormat(),
|
||||
info.nativeStreamMetadataFormatName(), info.nativeStreamMetadataFormatClassName(),
|
||||
info.extraStreamMetadataFormatNames(), info.extraStreamMetadataFormatClassNames(),
|
||||
info.supportsStandardImageMetadataFormat(),
|
||||
info.nativeImageMetadataFormatName(), info.nativeImageMetadataFormatClassName(),
|
||||
info.extraImageMetadataFormatNames(), info.extraImageMetadataFormatClassNames()
|
||||
);
|
||||
}
|
||||
}
|
@ -0,0 +1,157 @@
|
||||
package com.twelvemonkeys.imageio.spi;
|
||||
|
||||
import javax.imageio.stream.ImageInputStream;
|
||||
import javax.imageio.stream.ImageOutputStream;
|
||||
|
||||
import static com.twelvemonkeys.lang.Validate.notNull;
|
||||
|
||||
/**
|
||||
* ReaderWriterProviderInfo.
|
||||
*
|
||||
* @author <a href="mailto:harald.kuhr@gmail.com">Harald Kuhr</a>
|
||||
* @author last modified by $Author: harald.kuhr$
|
||||
* @version $Id: ReaderWriterProviderInfo.java,v 1.0 20/03/15 harald.kuhr Exp$
|
||||
*/
|
||||
public abstract class ReaderWriterProviderInfo extends ProviderInfo {
|
||||
|
||||
private final String[] formatNames;
|
||||
private final String[] suffixes;
|
||||
private final String[] mimeTypes;
|
||||
private final String readerClassName;
|
||||
private final String[] readerSpiClassNames;
|
||||
private final Class[] inputTypes = new Class[] {ImageInputStream.class};
|
||||
private final String writerClassName;
|
||||
private final String[] writerSpiClassNames;
|
||||
private final Class[] outputTypes = new Class[] {ImageOutputStream.class};
|
||||
private final boolean supportsStandardStreamMetadata;
|
||||
private final String nativeStreameMetadataFormatName;
|
||||
private final String nativeStreamMetadataFormatClassName;
|
||||
private final String[] extraStreamMetadataFormatNames;
|
||||
private final String[] extraStreamMetadataFormatClassNames;
|
||||
private final boolean supportsStandardImageMetadata;
|
||||
private final String nativeImageMetadataFormatName;
|
||||
private final String nativeImageMetadataFormatClassName;
|
||||
private final String[] extraImageMetadataFormatNames;
|
||||
private final String[] extraImageMetadataFormatClassNames;
|
||||
|
||||
/**
|
||||
* Creates a provider information instance based on the given class.
|
||||
*
|
||||
* @param infoClass the class to get provider information from.
|
||||
* The provider info will be taken from the class' package. @throws IllegalArgumentException if {@code pPackage == null}
|
||||
*/
|
||||
protected ReaderWriterProviderInfo(final Class<? extends ReaderWriterProviderInfo> infoClass,
|
||||
final String[] formatNames,
|
||||
final String[] suffixes,
|
||||
final String[] mimeTypes,
|
||||
final String readerClassName,
|
||||
final String[] readerSpiClassNames,
|
||||
final String writerClassName,
|
||||
final String[] writerSpiClassNames,
|
||||
final boolean supportsStandardStreamMetadata,
|
||||
final String nativeStreameMetadataFormatName,
|
||||
final String nativeStreamMetadataFormatClassName,
|
||||
final String[] extraStreamMetadataFormatNames,
|
||||
final String[] extraStreamMetadataFormatClassNames,
|
||||
final boolean supportsStandardImageMetadata,
|
||||
final String nativeImageMetadataFormatName,
|
||||
final String nativeImageMetadataFormatClassName,
|
||||
final String[] extraImageMetadataFormatNames,
|
||||
final String[] extraImageMetadataFormatClassNames) {
|
||||
super(notNull(infoClass).getPackage());
|
||||
|
||||
this.formatNames = formatNames;
|
||||
this.suffixes = suffixes;
|
||||
this.mimeTypes = mimeTypes;
|
||||
this.readerClassName = readerClassName;
|
||||
this.readerSpiClassNames = readerSpiClassNames;
|
||||
this.writerClassName = writerClassName;
|
||||
this.writerSpiClassNames = writerSpiClassNames;
|
||||
this.supportsStandardStreamMetadata = supportsStandardStreamMetadata;
|
||||
this.nativeStreameMetadataFormatName = nativeStreameMetadataFormatName;
|
||||
this.nativeStreamMetadataFormatClassName = nativeStreamMetadataFormatClassName;
|
||||
this.extraStreamMetadataFormatNames = extraStreamMetadataFormatNames;
|
||||
this.extraStreamMetadataFormatClassNames = extraStreamMetadataFormatClassNames;
|
||||
this.supportsStandardImageMetadata = supportsStandardImageMetadata;
|
||||
this.nativeImageMetadataFormatName = nativeImageMetadataFormatName;
|
||||
this.nativeImageMetadataFormatClassName = nativeImageMetadataFormatClassName;
|
||||
this.extraImageMetadataFormatNames = extraImageMetadataFormatNames;
|
||||
this.extraImageMetadataFormatClassNames = extraImageMetadataFormatClassNames;
|
||||
}
|
||||
|
||||
public String[] formatNames() {
|
||||
return formatNames;
|
||||
}
|
||||
|
||||
public String[] suffixes() {
|
||||
return suffixes;
|
||||
}
|
||||
|
||||
public String[] mimeTypes() {
|
||||
return mimeTypes;
|
||||
}
|
||||
|
||||
public String readerClassName() {
|
||||
return readerClassName;
|
||||
}
|
||||
|
||||
public String[] readerSpiClassNames() {
|
||||
return readerSpiClassNames;
|
||||
}
|
||||
|
||||
public Class[] inputTypes() {
|
||||
return inputTypes;
|
||||
}
|
||||
|
||||
public String writerClassName() {
|
||||
return writerClassName;
|
||||
}
|
||||
|
||||
public String[] writerSpiClassNames() {
|
||||
return writerSpiClassNames;
|
||||
}
|
||||
|
||||
public Class[] outputTypes() {
|
||||
return outputTypes;
|
||||
}
|
||||
|
||||
public boolean supportsStandardStreamMetadataFormat() {
|
||||
return supportsStandardStreamMetadata;
|
||||
}
|
||||
|
||||
public String nativeStreamMetadataFormatName() {
|
||||
return nativeStreameMetadataFormatName;
|
||||
}
|
||||
|
||||
public String nativeStreamMetadataFormatClassName() {
|
||||
return nativeStreamMetadataFormatClassName;
|
||||
}
|
||||
|
||||
public String[] extraStreamMetadataFormatNames() {
|
||||
return extraStreamMetadataFormatNames;
|
||||
}
|
||||
|
||||
public String[] extraStreamMetadataFormatClassNames() {
|
||||
return extraStreamMetadataFormatClassNames;
|
||||
}
|
||||
|
||||
public boolean supportsStandardImageMetadataFormat() {
|
||||
return supportsStandardImageMetadata;
|
||||
}
|
||||
|
||||
public String nativeImageMetadataFormatName() {
|
||||
return nativeImageMetadataFormatName;
|
||||
}
|
||||
|
||||
public String nativeImageMetadataFormatClassName() {
|
||||
return nativeImageMetadataFormatClassName;
|
||||
}
|
||||
|
||||
public String[] extraImageMetadataFormatNames() {
|
||||
return extraImageMetadataFormatNames;
|
||||
}
|
||||
|
||||
public String[] extraImageMetadataFormatClassNames() {
|
||||
return extraImageMetadataFormatClassNames;
|
||||
}
|
||||
}
|
@ -28,11 +28,9 @@
|
||||
|
||||
package com.twelvemonkeys.imageio.plugins.icns;
|
||||
|
||||
import com.twelvemonkeys.imageio.spi.ProviderInfo;
|
||||
import com.twelvemonkeys.imageio.util.IIOUtil;
|
||||
import com.twelvemonkeys.imageio.spi.ImageReaderSpiBase;
|
||||
|
||||
import javax.imageio.ImageReader;
|
||||
import javax.imageio.spi.ImageReaderSpi;
|
||||
import javax.imageio.stream.ImageInputStream;
|
||||
import java.io.IOException;
|
||||
import java.util.Locale;
|
||||
@ -44,28 +42,9 @@ import java.util.Locale;
|
||||
* @author last modified by $Author: haraldk$
|
||||
* @version $Id: ICNSImageReaderSpi.java,v 1.0 25.10.11 18:41 haraldk Exp$
|
||||
*/
|
||||
public final class ICNSImageReaderSpi extends ImageReaderSpi{
|
||||
public final class ICNSImageReaderSpi extends ImageReaderSpiBase {
|
||||
public ICNSImageReaderSpi() {
|
||||
this(IIOUtil.getProviderInfo(ICNSImageReaderSpi.class));
|
||||
}
|
||||
|
||||
private ICNSImageReaderSpi(final ProviderInfo pProviderInfo) {
|
||||
super(
|
||||
pProviderInfo.getVendorName(),
|
||||
pProviderInfo.getVersion(),
|
||||
new String[]{"icns", "ICNS"},
|
||||
new String[]{"icns"},
|
||||
new String[]{
|
||||
"image/x-apple-icons", // Common extension MIME
|
||||
},
|
||||
"com.twelvemonkeys.imageio.plugins.icns.ICNSImageReader",
|
||||
new Class[] {ImageInputStream.class},
|
||||
null,
|
||||
true, null, null, null, null,
|
||||
true,
|
||||
null, null,
|
||||
null, null
|
||||
);
|
||||
super(new ICNSProviderInfo());
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -0,0 +1,28 @@
|
||||
package com.twelvemonkeys.imageio.plugins.icns;
|
||||
|
||||
import com.twelvemonkeys.imageio.spi.ReaderWriterProviderInfo;
|
||||
|
||||
/**
|
||||
* ICNSProviderInfo.
|
||||
*
|
||||
* @author <a href="mailto:harald.kuhr@gmail.com">Harald Kuhr</a>
|
||||
* @author last modified by $Author: harald.kuhr$
|
||||
* @version $Id: ICNSProviderInfo.java,v 1.0 20/03/15 harald.kuhr Exp$
|
||||
*/
|
||||
final class ICNSProviderInfo extends ReaderWriterProviderInfo {
|
||||
protected ICNSProviderInfo() {
|
||||
super(
|
||||
ICNSProviderInfo.class,
|
||||
new String[]{"icns", "ICNS"},
|
||||
new String[]{"icns"},
|
||||
new String[]{
|
||||
"image/x-apple-icons", // Common extension MIME
|
||||
},
|
||||
"com.twelvemonkeys.imageio.plugins.icns.ICNSImageReader",
|
||||
new String[] {"com.twelvemonkeys.imageio.plugins.ics.ICNImageReaderSpi"},
|
||||
null, null,
|
||||
false, null, null, null, null,
|
||||
true, null, null, null, null
|
||||
);
|
||||
}
|
||||
}
|
@ -113,7 +113,7 @@ public class IFFImageReader extends ImageReaderBase {
|
||||
private DataInputStream byteRunStream;
|
||||
|
||||
public IFFImageReader() {
|
||||
super(IFFImageReaderSpi.sharedProvider());
|
||||
super(new IFFImageReaderSpi());
|
||||
}
|
||||
|
||||
protected IFFImageReader(ImageReaderSpi pProvider) {
|
||||
|
@ -28,11 +28,9 @@
|
||||
|
||||
package com.twelvemonkeys.imageio.plugins.iff;
|
||||
|
||||
import com.twelvemonkeys.imageio.spi.ProviderInfo;
|
||||
import com.twelvemonkeys.imageio.util.IIOUtil;
|
||||
import com.twelvemonkeys.imageio.spi.ImageReaderSpiBase;
|
||||
|
||||
import javax.imageio.ImageReader;
|
||||
import javax.imageio.spi.ImageReaderSpi;
|
||||
import javax.imageio.stream.ImageInputStream;
|
||||
import java.io.IOException;
|
||||
import java.util.Locale;
|
||||
@ -44,34 +42,13 @@ import java.util.Locale;
|
||||
* @author <a href="mailto:harald.kuhr@gmail.com">Harald Kuhr</a>
|
||||
* @version $Id: IFFImageWriterSpi.java,v 1.0 28.feb.2006 19:21:05 haku Exp$
|
||||
*/
|
||||
public class IFFImageReaderSpi extends ImageReaderSpi {
|
||||
|
||||
static IFFImageReaderSpi mSharedInstance;
|
||||
public class IFFImageReaderSpi extends ImageReaderSpiBase {
|
||||
|
||||
/**
|
||||
* Creates an {@code IFFImageReaderSpi}.
|
||||
*/
|
||||
public IFFImageReaderSpi() {
|
||||
this(IIOUtil.getProviderInfo(IFFImageReaderSpi.class));
|
||||
}
|
||||
|
||||
private IFFImageReaderSpi(final ProviderInfo pProviderInfo) {
|
||||
super(
|
||||
pProviderInfo.getVendorName(),
|
||||
pProviderInfo.getVersion(),
|
||||
new String[]{"iff", "IFF"},
|
||||
new String[]{"iff", "lbm", "ham", "ham8", "ilbm"},
|
||||
new String[]{"image/iff", "image/x-iff"},
|
||||
"com.twelvemonkeys.imageio.plugins.iff.IFFImageReader",
|
||||
new Class[] {ImageInputStream.class},
|
||||
new String[]{"com.twelvemonkeys.imageio.plugins.iff.IFFImageWriterSpi"},
|
||||
true, null, null, null, null,
|
||||
true, null, null, null, null
|
||||
);
|
||||
|
||||
if (mSharedInstance == null) {
|
||||
mSharedInstance = this;
|
||||
}
|
||||
super(new IFFProviderInfo());
|
||||
}
|
||||
|
||||
public boolean canDecodeInput(Object pSource) throws IOException {
|
||||
@ -102,7 +79,6 @@ public class IFFImageReaderSpi extends ImageReaderSpi {
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
public ImageReader createReaderInstance(Object pExtension) throws IOException {
|
||||
return new IFFImageReader(this);
|
||||
}
|
||||
@ -110,12 +86,4 @@ public class IFFImageReaderSpi extends ImageReaderSpi {
|
||||
public String getDescription(Locale pLocale) {
|
||||
return "Commodore Amiga/Electronic Arts Image Interchange Format (IFF) image reader";
|
||||
}
|
||||
|
||||
public static ImageReaderSpi sharedProvider() {
|
||||
if (mSharedInstance == null) {
|
||||
new IFFImageReaderSpi();
|
||||
}
|
||||
|
||||
return mSharedInstance;
|
||||
}
|
||||
}
|
||||
|
@ -28,12 +28,10 @@
|
||||
|
||||
package com.twelvemonkeys.imageio.plugins.iff;
|
||||
|
||||
import com.twelvemonkeys.imageio.spi.ProviderInfo;
|
||||
import com.twelvemonkeys.imageio.util.IIOUtil;
|
||||
import com.twelvemonkeys.imageio.spi.ImageWriterSpiBase;
|
||||
|
||||
import javax.imageio.ImageTypeSpecifier;
|
||||
import javax.imageio.ImageWriter;
|
||||
import javax.imageio.spi.ImageWriterSpi;
|
||||
import java.io.IOException;
|
||||
import java.util.Locale;
|
||||
|
||||
@ -44,28 +42,13 @@ import java.util.Locale;
|
||||
* @author <a href="mailto:harald.kuhr@gmail.com">Harald Kuhr</a>
|
||||
* @version $Id: IFFImageWriterSpi.java,v 1.0 02.mar.2006 19:21:05 haku Exp$
|
||||
*/
|
||||
public class IFFImageWriterSpi extends ImageWriterSpi {
|
||||
public class IFFImageWriterSpi extends ImageWriterSpiBase {
|
||||
|
||||
/**
|
||||
* Creates an {@code IFFImageWriterSpi}.
|
||||
*/
|
||||
public IFFImageWriterSpi() {
|
||||
this(IIOUtil.getProviderInfo(IFFImageWriterSpi.class));
|
||||
}
|
||||
|
||||
private IFFImageWriterSpi(final ProviderInfo pProviderInfo) {
|
||||
super(
|
||||
pProviderInfo.getVendorName(),
|
||||
pProviderInfo.getVersion(),
|
||||
new String[]{"iff", "IFF"},
|
||||
new String[]{"iff", "lbm", "ham", "ham8", "ilbm"},
|
||||
new String[]{"image/iff", "image/x-iff"},
|
||||
"com.twelvemonkeys.imageio.plugins.iff.IFFImageWriter",
|
||||
STANDARD_OUTPUT_TYPE,
|
||||
new String[]{"com.twelvemonkeys.imageio.plugins.iff.IFFImageReaderSpi"},
|
||||
true, null, null, null, null,
|
||||
true, null, null, null, null
|
||||
);
|
||||
super(new IFFProviderInfo());
|
||||
}
|
||||
|
||||
public boolean canEncodeImage(final ImageTypeSpecifier pType) {
|
||||
|
@ -0,0 +1,27 @@
|
||||
package com.twelvemonkeys.imageio.plugins.iff;
|
||||
|
||||
import com.twelvemonkeys.imageio.spi.ReaderWriterProviderInfo;
|
||||
|
||||
/**
|
||||
* IFFProviderInfo.
|
||||
*
|
||||
* @author <a href="mailto:harald.kuhr@gmail.com">Harald Kuhr</a>
|
||||
* @author last modified by $Author: harald.kuhr$
|
||||
* @version $Id: IFFProviderInfo.java,v 1.0 20/03/15 harald.kuhr Exp$
|
||||
*/
|
||||
final class IFFProviderInfo extends ReaderWriterProviderInfo {
|
||||
protected IFFProviderInfo() {
|
||||
super(
|
||||
IFFProviderInfo.class,
|
||||
new String[] {"iff", "IFF"},
|
||||
new String[] {"iff", "lbm", "ham", "ham8", "ilbm"},
|
||||
new String[] {"image/iff", "image/x-iff"},
|
||||
"com.twelvemonkeys.imageio.plugins.iff.IFFImageReader",
|
||||
new String[]{"com.twelvemonkeys.imageio.plugins.iff.IFFImageReaderSpi"},
|
||||
"com.twelvemonkeys.imageio.plugins.iff.IFFImageWriter",
|
||||
new String[] {"com.twelvemonkeys.imageio.plugins.iff.IFFImageWriterSpi"},
|
||||
false, null, null, null, null,
|
||||
true, null, null, null, null
|
||||
);
|
||||
}
|
||||
}
|
@ -0,0 +1,33 @@
|
||||
package com.twelvemonkeys.imageio.plugins.dcx;
|
||||
|
||||
import com.twelvemonkeys.imageio.spi.ReaderWriterProviderInfo;
|
||||
|
||||
/**
|
||||
* DCXProviderInfo.
|
||||
*
|
||||
* @author <a href="mailto:harald.kuhr@gmail.com">Harald Kuhr</a>
|
||||
* @author last modified by $Author: harald.kuhr$
|
||||
* @version $Id: DCXProviderInfo.java,v 1.0 20/03/15 harald.kuhr Exp$
|
||||
*/
|
||||
final class DCXProviderInfo extends ReaderWriterProviderInfo {
|
||||
protected DCXProviderInfo() {
|
||||
super(
|
||||
DCXProviderInfo.class,
|
||||
new String[]{
|
||||
"dcx",
|
||||
"DCX"
|
||||
},
|
||||
new String[]{"dcx"},
|
||||
new String[]{
|
||||
// No official IANA record exists
|
||||
"image/dcx",
|
||||
"image/x-dcx",
|
||||
},
|
||||
"com.twelvemkonkeys.imageio.plugins.dcx.DCXImageReader",
|
||||
new String[] {"com.twelvemkonkeys.imageio.plugins.dcx.DCXImageReaderSpi"},
|
||||
null, null,
|
||||
false, null, null, null, null,
|
||||
true, null, null, null, null
|
||||
);
|
||||
}
|
||||
}
|
@ -28,48 +28,20 @@
|
||||
|
||||
package com.twelvemonkeys.imageio.plugins.pcx;
|
||||
|
||||
import com.twelvemonkeys.imageio.spi.ProviderInfo;
|
||||
import com.twelvemonkeys.imageio.util.IIOUtil;
|
||||
import com.twelvemonkeys.imageio.spi.ImageReaderSpiBase;
|
||||
|
||||
import javax.imageio.ImageReader;
|
||||
import javax.imageio.spi.ImageReaderSpi;
|
||||
import javax.imageio.stream.ImageInputStream;
|
||||
import java.io.IOException;
|
||||
import java.util.Locale;
|
||||
|
||||
public final class PCXImageReaderSpi extends ImageReaderSpi {
|
||||
public final class PCXImageReaderSpi extends ImageReaderSpiBase {
|
||||
|
||||
/**
|
||||
* Creates a {@code PCXImageReaderSpi}.
|
||||
*/
|
||||
public PCXImageReaderSpi() {
|
||||
this(IIOUtil.getProviderInfo(PCXImageReaderSpi.class));
|
||||
}
|
||||
|
||||
private PCXImageReaderSpi(final ProviderInfo providerInfo) {
|
||||
super(
|
||||
providerInfo.getVendorName(),
|
||||
providerInfo.getVersion(),
|
||||
new String[]{
|
||||
"pcx",
|
||||
"PCX"
|
||||
},
|
||||
new String[]{"pcx"},
|
||||
new String[]{
|
||||
// No official IANA record exists
|
||||
"image/pcx",
|
||||
"image/x-pcx",
|
||||
},
|
||||
"com.twelvemkonkeys.imageio.plugins.pcx.PCXImageReader",
|
||||
new Class[] {ImageInputStream.class},
|
||||
null,
|
||||
true, // supports standard stream metadata
|
||||
null, null, // native stream format name and class
|
||||
null, null, // extra stream formats
|
||||
true, // supports standard image metadata
|
||||
null, null,
|
||||
null, null // extra image metadata formats
|
||||
);
|
||||
super(new PCXProviderInfo());
|
||||
}
|
||||
|
||||
@Override public boolean canDecodeInput(final Object source) throws IOException {
|
||||
|
@ -0,0 +1,33 @@
|
||||
package com.twelvemonkeys.imageio.plugins.pcx;
|
||||
|
||||
import com.twelvemonkeys.imageio.spi.ReaderWriterProviderInfo;
|
||||
|
||||
/**
|
||||
* PCXProviderInfo.
|
||||
*
|
||||
* @author <a href="mailto:harald.kuhr@gmail.com">Harald Kuhr</a>
|
||||
* @author last modified by $Author: harald.kuhr$
|
||||
* @version $Id: PCXProviderInfo.java,v 1.0 20/03/15 harald.kuhr Exp$
|
||||
*/
|
||||
final class PCXProviderInfo extends ReaderWriterProviderInfo {
|
||||
protected PCXProviderInfo() {
|
||||
super(
|
||||
PCXProviderInfo.class,
|
||||
new String[]{
|
||||
"pcx",
|
||||
"PCX"
|
||||
},
|
||||
new String[]{"pcx"},
|
||||
new String[]{
|
||||
// No official IANA record exists
|
||||
"image/pcx",
|
||||
"image/x-pcx",
|
||||
},
|
||||
"com.twelvemkonkeys.imageio.plugins.pcx.PCXImageReader",
|
||||
new String[] {"com.twelvemkonkeys.imageio.plugins.pcx.PCXImageReaderSpi"},
|
||||
null, null,
|
||||
false, null, null, null, null,
|
||||
true, null, null, null, null
|
||||
);
|
||||
}
|
||||
}
|
@ -28,11 +28,9 @@
|
||||
|
||||
package com.twelvemonkeys.imageio.plugins.pict;
|
||||
|
||||
import com.twelvemonkeys.imageio.spi.ProviderInfo;
|
||||
import com.twelvemonkeys.imageio.util.IIOUtil;
|
||||
import com.twelvemonkeys.imageio.spi.ImageReaderSpiBase;
|
||||
|
||||
import javax.imageio.ImageReader;
|
||||
import javax.imageio.spi.ImageReaderSpi;
|
||||
import javax.imageio.stream.ImageInputStream;
|
||||
import java.io.EOFException;
|
||||
import java.io.IOException;
|
||||
@ -45,28 +43,13 @@ import java.util.Locale;
|
||||
* @author <a href="mailto:harald.kuhr@gmail.com">Harald Kuhr</a>
|
||||
* @version $Id: PICTImageReaderSpi.java,v 1.0 28.feb.2006 19:21:05 haku Exp$
|
||||
*/
|
||||
public class PICTImageReaderSpi extends ImageReaderSpi {
|
||||
public class PICTImageReaderSpi extends ImageReaderSpiBase {
|
||||
|
||||
/**
|
||||
* Creates a {@code PICTImageReaderSpi}.
|
||||
*/
|
||||
public PICTImageReaderSpi() {
|
||||
this(IIOUtil.getProviderInfo(PICTImageReaderSpi.class));
|
||||
}
|
||||
|
||||
private PICTImageReaderSpi(final ProviderInfo pProviderInfo) {
|
||||
super(
|
||||
pProviderInfo.getVendorName(),
|
||||
pProviderInfo.getVersion(),
|
||||
new String[]{"pct", "PCT", "pict", "PICT"},
|
||||
new String[]{"pct", "pict"},
|
||||
new String[]{"image/pict", "image/x-pict"},
|
||||
"com.twelvemkonkeys.imageio.plugins.pict.PICTImageReader",
|
||||
new Class[] {ImageInputStream.class},
|
||||
new String[]{"com.twelvemkonkeys.imageio.plugins.pict.PICTImageWriterSpi"},
|
||||
true, null, null, null, null,
|
||||
true, null, null, null, null
|
||||
);
|
||||
super(new PICTProviderInfo());
|
||||
}
|
||||
|
||||
public boolean canDecodeInput(final Object pSource) throws IOException {
|
||||
|
@ -28,12 +28,10 @@
|
||||
|
||||
package com.twelvemonkeys.imageio.plugins.pict;
|
||||
|
||||
import com.twelvemonkeys.imageio.spi.ProviderInfo;
|
||||
import com.twelvemonkeys.imageio.util.IIOUtil;
|
||||
import com.twelvemonkeys.imageio.spi.ImageWriterSpiBase;
|
||||
|
||||
import javax.imageio.ImageTypeSpecifier;
|
||||
import javax.imageio.ImageWriter;
|
||||
import javax.imageio.spi.ImageWriterSpi;
|
||||
import java.io.IOException;
|
||||
import java.util.Locale;
|
||||
|
||||
@ -44,29 +42,13 @@ import java.util.Locale;
|
||||
* @author <a href="mailto:harald.kuhr@gmail.com">Harald Kuhr</a>
|
||||
* @version $Id: PICTImageWriterSpi.java,v 1.0 02.mar.2006 19:21:05 haku Exp$
|
||||
*/
|
||||
public class PICTImageWriterSpi extends ImageWriterSpi {
|
||||
public class PICTImageWriterSpi extends ImageWriterSpiBase {
|
||||
|
||||
/**
|
||||
* Creates a {@code PICTImageWriterSpi}.
|
||||
*/
|
||||
public PICTImageWriterSpi() {
|
||||
this(IIOUtil.getProviderInfo(PICTImageWriterSpi.class));
|
||||
}
|
||||
|
||||
private PICTImageWriterSpi(final ProviderInfo pProviderInfo) {
|
||||
super(
|
||||
pProviderInfo.getVendorName(),
|
||||
pProviderInfo.getVersion(),
|
||||
new String[]{"pct", "PCT",
|
||||
"pict", "PICT"},
|
||||
new String[]{"pct", "pict"},
|
||||
new String[]{"image/pict", "image/x-pict"},
|
||||
"com.twelvemonkeys.imageio.plugins.pict.PICTImageWriter",
|
||||
STANDARD_OUTPUT_TYPE,
|
||||
new String[]{"com.twelvemonkeys.imageio.plugins.pict.PICTImageReaderSpi"},
|
||||
true, null, null, null, null,
|
||||
true, null, null, null, null
|
||||
);
|
||||
super(new PICTProviderInfo());
|
||||
}
|
||||
|
||||
public boolean canEncodeImage(ImageTypeSpecifier pType) {
|
||||
|
@ -0,0 +1,27 @@
|
||||
package com.twelvemonkeys.imageio.plugins.pict;
|
||||
|
||||
import com.twelvemonkeys.imageio.spi.ReaderWriterProviderInfo;
|
||||
|
||||
/**
|
||||
* PICTProviderInfo.
|
||||
*
|
||||
* @author <a href="mailto:harald.kuhr@gmail.com">Harald Kuhr</a>
|
||||
* @author last modified by $Author: harald.kuhr$
|
||||
* @version $Id: PICTProviderInfo.java,v 1.0 20/03/15 harald.kuhr Exp$
|
||||
*/
|
||||
final class PICTProviderInfo extends ReaderWriterProviderInfo {
|
||||
protected PICTProviderInfo() {
|
||||
super(
|
||||
PICTProviderInfo.class,
|
||||
new String[] {"pct", "PCT", "pict", "PICT"},
|
||||
new String[] {"pct", "pict"},
|
||||
new String[] {"image/pict", "image/x-pict"},
|
||||
"com.twelvemkonkeys.imageio.plugins.pict.PICTImageReader",
|
||||
new String[] {"com.twelvemonkeys.imageio.plugins.pict.PICTImageReaderSpi"},
|
||||
"com.twelvemonkeys.imageio.plugins.pict.PICTImageWriter",
|
||||
new String[] {"com.twelvemkonkeys.imageio.plugins.pict.PICTImageWriterSpi"},
|
||||
false, null, null, null, null,
|
||||
true, null, null, null, null
|
||||
);
|
||||
}
|
||||
}
|
@ -29,7 +29,6 @@
|
||||
package com.twelvemonkeys.imageio.plugins.pnm;
|
||||
|
||||
import com.twelvemonkeys.imageio.spi.ProviderInfo;
|
||||
import com.twelvemonkeys.imageio.util.IIOUtil;
|
||||
|
||||
import javax.imageio.ImageTypeSpecifier;
|
||||
import javax.imageio.ImageWriter;
|
||||
@ -43,16 +42,16 @@ public final class PAMImageWriterSpi extends ImageWriterSpi {
|
||||
* Creates a {@code PAMImageWriterSpi}.
|
||||
*/
|
||||
public PAMImageWriterSpi() {
|
||||
this(IIOUtil.getProviderInfo(PAMImageWriterSpi.class));
|
||||
this(new PNMProviderInfo());
|
||||
}
|
||||
|
||||
private PAMImageWriterSpi(final ProviderInfo pProviderInfo) {
|
||||
super(
|
||||
pProviderInfo.getVendorName(),
|
||||
pProviderInfo.getVersion(),
|
||||
new String[]{"pam", "PAM"},
|
||||
new String[]{"pam"},
|
||||
new String[]{
|
||||
new String[] {"pam", "PAM"},
|
||||
new String[] {"pam"},
|
||||
new String[] {
|
||||
// No official IANA record exists, these are conventional
|
||||
"image/x-portable-arbitrarymap" // PAM
|
||||
},
|
||||
@ -73,7 +72,8 @@ public final class PAMImageWriterSpi extends ImageWriterSpi {
|
||||
return new PNMImageWriter(this);
|
||||
}
|
||||
|
||||
@Override public String getDescription(final Locale locale) {
|
||||
@Override
|
||||
public String getDescription(final Locale locale) {
|
||||
return "NetPBM Portable Arbitrary Map (PAM) image writer";
|
||||
}
|
||||
}
|
||||
|
@ -29,7 +29,6 @@
|
||||
package com.twelvemonkeys.imageio.plugins.pnm;
|
||||
|
||||
import com.twelvemonkeys.imageio.spi.ProviderInfo;
|
||||
import com.twelvemonkeys.imageio.util.IIOUtil;
|
||||
|
||||
import javax.imageio.ImageReader;
|
||||
import javax.imageio.spi.ImageReaderSpi;
|
||||
@ -43,19 +42,19 @@ public final class PNMImageReaderSpi extends ImageReaderSpi {
|
||||
* Creates a {@code PNMImageReaderSpi}.
|
||||
*/
|
||||
public PNMImageReaderSpi() {
|
||||
this(IIOUtil.getProviderInfo(PNMImageReaderSpi.class));
|
||||
this(new PNMProviderInfo());
|
||||
}
|
||||
|
||||
private PNMImageReaderSpi(final ProviderInfo providerInfo) {
|
||||
super(
|
||||
providerInfo.getVendorName(),
|
||||
providerInfo.getVersion(),
|
||||
new String[]{
|
||||
"pnm", "pbm", "pgm", "ppm", "pam",
|
||||
"PNM", "PBM", "PGM", "PPM", "PAM"
|
||||
new String[] {
|
||||
"pnm", "pbm", "pgm", "ppm", "pam", "pfm",
|
||||
"PNM", "PBM", "PGM", "PPM", "PAM", "PFM"
|
||||
},
|
||||
new String[]{"pbm", "pgm", "ppm", "pam"},
|
||||
new String[]{
|
||||
new String[] {"pbm", "pgm", "ppm", "pam", "pfm"},
|
||||
new String[] {
|
||||
// No official IANA record exists, these are conventional
|
||||
"image/x-portable-pixmap",
|
||||
"image/x-portable-anymap",
|
||||
@ -63,7 +62,7 @@ public final class PNMImageReaderSpi extends ImageReaderSpi {
|
||||
},
|
||||
"com.twelvemkonkeys.imageio.plugins.pnm.PNMImageReader",
|
||||
new Class[] {ImageInputStream.class},
|
||||
new String[]{
|
||||
new String[] {
|
||||
"com.twelvemkonkeys.imageio.plugins.pnm.PNMImageWriterSpi",
|
||||
"com.twelvemkonkeys.imageio.plugins.pnm.PAMImageWriterSpi"
|
||||
},
|
||||
@ -76,7 +75,8 @@ public final class PNMImageReaderSpi extends ImageReaderSpi {
|
||||
);
|
||||
}
|
||||
|
||||
@Override public boolean canDecodeInput(final Object source) throws IOException {
|
||||
@Override
|
||||
public boolean canDecodeInput(final Object source) throws IOException {
|
||||
if (!(source instanceof ImageInputStream)) {
|
||||
return false;
|
||||
}
|
||||
@ -109,11 +109,13 @@ public final class PNMImageReaderSpi extends ImageReaderSpi {
|
||||
}
|
||||
}
|
||||
|
||||
@Override public ImageReader createReaderInstance(final Object extension) throws IOException {
|
||||
@Override
|
||||
public ImageReader createReaderInstance(final Object extension) throws IOException {
|
||||
return new PNMImageReader(this);
|
||||
}
|
||||
|
||||
@Override public String getDescription(final Locale locale) {
|
||||
@Override
|
||||
public String getDescription(final Locale locale) {
|
||||
return "NetPBM Portable Any Map (PNM and PAM) image reader";
|
||||
}
|
||||
}
|
||||
|
@ -29,7 +29,6 @@
|
||||
package com.twelvemonkeys.imageio.plugins.pnm;
|
||||
|
||||
import com.twelvemonkeys.imageio.spi.ProviderInfo;
|
||||
import com.twelvemonkeys.imageio.util.IIOUtil;
|
||||
|
||||
import javax.imageio.ImageTypeSpecifier;
|
||||
import javax.imageio.ImageWriter;
|
||||
@ -41,23 +40,24 @@ public final class PNMImageWriterSpi extends ImageWriterSpi {
|
||||
|
||||
// TODO: Consider one Spi for each sub-format, as it makes no sense for the writer to write PPM if client code requested PBM or PGM format.
|
||||
// ...Then again, what if user asks for PNM? :-P
|
||||
|
||||
/**
|
||||
* Creates a {@code PNMImageWriterSpi}.
|
||||
*/
|
||||
public PNMImageWriterSpi() {
|
||||
this(IIOUtil.getProviderInfo(PNMImageWriterSpi.class));
|
||||
this(new PNMProviderInfo());
|
||||
}
|
||||
|
||||
private PNMImageWriterSpi(final ProviderInfo pProviderInfo) {
|
||||
super(
|
||||
pProviderInfo.getVendorName(),
|
||||
pProviderInfo.getVersion(),
|
||||
new String[]{
|
||||
new String[] {
|
||||
"pnm", "pbm", "pgm", "ppm",
|
||||
"PNM", "PBM", "PGM", "PPM"
|
||||
},
|
||||
new String[]{"pbm", "pgm", "ppm"},
|
||||
new String[]{
|
||||
new String[] {"pbm", "pgm", "ppm"},
|
||||
new String[] {
|
||||
// No official IANA record exists, these are conventional
|
||||
"image/x-portable-pixmap",
|
||||
"image/x-portable-anymap"
|
||||
@ -79,7 +79,8 @@ public final class PNMImageWriterSpi extends ImageWriterSpi {
|
||||
return new PNMImageWriter(this);
|
||||
}
|
||||
|
||||
@Override public String getDescription(final Locale locale) {
|
||||
@Override
|
||||
public String getDescription(final Locale locale) {
|
||||
return "NetPBM Portable Any Map (PNM) image writer";
|
||||
}
|
||||
}
|
||||
|
@ -0,0 +1,19 @@
|
||||
package com.twelvemonkeys.imageio.plugins.pnm;
|
||||
|
||||
import com.twelvemonkeys.imageio.spi.ProviderInfo;
|
||||
|
||||
/**
|
||||
* PNMProviderInfo.
|
||||
*
|
||||
* @author <a href="mailto:harald.kuhr@gmail.com">Harald Kuhr</a>
|
||||
* @author last modified by $Author: harald.kuhr$
|
||||
* @version $Id: PNMProviderInfo.java,v 1.0 20/03/15 harald.kuhr Exp$
|
||||
*/
|
||||
class PNMProviderInfo extends ProviderInfo {
|
||||
// NOTE: Because the ReaderSpi and the two WriterSpis supports different formats,
|
||||
// we don't use the standard ImageReaderWriterProviderInfo superclass here.
|
||||
|
||||
public PNMProviderInfo() {
|
||||
super(PNMProviderInfo.class.getPackage());
|
||||
}
|
||||
}
|
@ -28,11 +28,9 @@
|
||||
|
||||
package com.twelvemonkeys.imageio.plugins.psd;
|
||||
|
||||
import com.twelvemonkeys.imageio.spi.ProviderInfo;
|
||||
import com.twelvemonkeys.imageio.util.IIOUtil;
|
||||
import com.twelvemonkeys.imageio.spi.ImageReaderSpiBase;
|
||||
|
||||
import javax.imageio.ImageReader;
|
||||
import javax.imageio.spi.ImageReaderSpi;
|
||||
import javax.imageio.stream.ImageInputStream;
|
||||
import java.io.IOException;
|
||||
import java.util.Locale;
|
||||
@ -44,39 +42,13 @@ import java.util.Locale;
|
||||
* @author last modified by $Author: haraldk$
|
||||
* @version $Id: PSDImageReaderSpi.java,v 1.0 Apr 29, 2008 4:49:03 PM haraldk Exp$
|
||||
*/
|
||||
final public class PSDImageReaderSpi extends ImageReaderSpi {
|
||||
final public class PSDImageReaderSpi extends ImageReaderSpiBase {
|
||||
|
||||
/**
|
||||
* Creates a {@code PSDImageReaderSpi}.
|
||||
*/
|
||||
public PSDImageReaderSpi() {
|
||||
this(IIOUtil.getProviderInfo(PSDImageReaderSpi.class));
|
||||
}
|
||||
|
||||
private PSDImageReaderSpi(final ProviderInfo providerInfo) {
|
||||
super(
|
||||
providerInfo.getVendorName(),
|
||||
providerInfo.getVersion(),
|
||||
new String[] {"psd", "PSD"},
|
||||
new String[] {"psd"},
|
||||
new String[] {
|
||||
"image/vnd.adobe.photoshop", // Official, IANA registered
|
||||
"application/vnd.adobe.photoshop", // Used in XMP
|
||||
"image/x-psd",
|
||||
"application/x-photoshop",
|
||||
"image/x-photoshop"
|
||||
},
|
||||
"com.twelvemkonkeys.imageio.plugins.psd.PSDImageReader",
|
||||
new Class[] {ImageInputStream.class},
|
||||
// new String[] {"com.twelvemkonkeys.imageio.plugins.psd.PSDImageWriterSpi"},
|
||||
null,
|
||||
true, // supports standard stream metadata
|
||||
null, null, // native stream format name and class
|
||||
null, null, // extra stream formats
|
||||
true, // supports standard image metadata
|
||||
PSDMetadata.NATIVE_METADATA_FORMAT_NAME, PSDMetadata.NATIVE_METADATA_FORMAT_CLASS_NAME,
|
||||
null, null // extra image metadata formats
|
||||
);
|
||||
super(new PSDProviderInfo());
|
||||
}
|
||||
|
||||
public boolean canDecodeInput(final Object pSource) throws IOException {
|
||||
|
@ -0,0 +1,33 @@
|
||||
package com.twelvemonkeys.imageio.plugins.psd;
|
||||
|
||||
import com.twelvemonkeys.imageio.spi.ReaderWriterProviderInfo;
|
||||
|
||||
/**
|
||||
* PSDProviderInfo.
|
||||
*
|
||||
* @author <a href="mailto:harald.kuhr@gmail.com">Harald Kuhr</a>
|
||||
* @author last modified by $Author: harald.kuhr$
|
||||
* @version $Id: PSDProviderInfo.java,v 1.0 20/03/15 harald.kuhr Exp$
|
||||
*/
|
||||
final class PSDProviderInfo extends ReaderWriterProviderInfo {
|
||||
protected PSDProviderInfo() {
|
||||
super(
|
||||
PSDProviderInfo.class,
|
||||
new String[] {"psd", "PSD"},
|
||||
new String[] {"psd"},
|
||||
new String[] {
|
||||
"image/vnd.adobe.photoshop", // Official, IANA registered
|
||||
"application/vnd.adobe.photoshop", // Used in XMP
|
||||
"image/x-psd",
|
||||
"application/x-photoshop",
|
||||
"image/x-photoshop"
|
||||
},
|
||||
"com.twelvemkonkeys.imageio.plugins.psd.PSDImageReader",
|
||||
new String[] {"com.twelvemonkeys.imageio.plugins.psd.PSDImageReaderSpi"},
|
||||
null,
|
||||
null, // new String[] {"com.twelvemkonkeys.imageio.plugins.psd.PSDImageWriterSpi"},
|
||||
false, null, null, null, null,
|
||||
true, PSDMetadata.NATIVE_METADATA_FORMAT_NAME, PSDMetadata.NATIVE_METADATA_FORMAT_CLASS_NAME, null, null
|
||||
);
|
||||
}
|
||||
}
|
@ -28,48 +28,20 @@
|
||||
|
||||
package com.twelvemonkeys.imageio.plugins.sgi;
|
||||
|
||||
import com.twelvemonkeys.imageio.spi.ProviderInfo;
|
||||
import com.twelvemonkeys.imageio.util.IIOUtil;
|
||||
import com.twelvemonkeys.imageio.spi.ImageReaderSpiBase;
|
||||
|
||||
import javax.imageio.ImageReader;
|
||||
import javax.imageio.spi.ImageReaderSpi;
|
||||
import javax.imageio.stream.ImageInputStream;
|
||||
import java.io.IOException;
|
||||
import java.util.Locale;
|
||||
|
||||
public final class SGIImageReaderSpi extends ImageReaderSpi {
|
||||
public final class SGIImageReaderSpi extends ImageReaderSpiBase {
|
||||
|
||||
/**
|
||||
* Creates a {@code SGIImageReaderSpi}.
|
||||
*/
|
||||
public SGIImageReaderSpi() {
|
||||
this(IIOUtil.getProviderInfo(SGIImageReaderSpi.class));
|
||||
}
|
||||
|
||||
private SGIImageReaderSpi(final ProviderInfo providerInfo) {
|
||||
super(
|
||||
providerInfo.getVendorName(),
|
||||
providerInfo.getVersion(),
|
||||
new String[]{
|
||||
"sgi",
|
||||
"SGI"
|
||||
},
|
||||
new String[]{"sgi"},
|
||||
new String[]{
|
||||
// No official IANA record exists
|
||||
"image/sgi",
|
||||
"image/x-sgi",
|
||||
},
|
||||
"com.twelvemkonkeys.imageio.plugins.sgi.SGIImageReader",
|
||||
new Class[] {ImageInputStream.class},
|
||||
null,
|
||||
true, // supports standard stream metadata
|
||||
null, null, // native stream format name and class
|
||||
null, null, // extra stream formats
|
||||
true, // supports standard image metadata
|
||||
null, null,
|
||||
null, null // extra image metadata formats
|
||||
);
|
||||
super(new SGIProviderInfo());
|
||||
}
|
||||
|
||||
@Override public boolean canDecodeInput(final Object source) throws IOException {
|
||||
|
@ -0,0 +1,34 @@
|
||||
package com.twelvemonkeys.imageio.plugins.sgi;
|
||||
|
||||
import com.twelvemonkeys.imageio.spi.ReaderWriterProviderInfo;
|
||||
|
||||
/**
|
||||
* SGIProviderInfo.
|
||||
*
|
||||
* @author <a href="mailto:harald.kuhr@gmail.com">Harald Kuhr</a>
|
||||
* @author last modified by $Author: harald.kuhr$
|
||||
* @version $Id: SGIProviderInfo.java,v 1.0 20/03/15 harald.kuhr Exp$
|
||||
*/
|
||||
final class SGIProviderInfo extends ReaderWriterProviderInfo {
|
||||
protected SGIProviderInfo() {
|
||||
super(
|
||||
SGIProviderInfo.class,
|
||||
new String[] {
|
||||
"sgi",
|
||||
"SGI"
|
||||
},
|
||||
new String[] {"sgi"},
|
||||
new String[] {
|
||||
// No official IANA record exists
|
||||
"image/sgi",
|
||||
"image/x-sgi",
|
||||
},
|
||||
"com.twelvemkonkeys.imageio.plugins.sgi.SGIImageReader",
|
||||
new String[] {"com.twelvemonkeys.imageio.plugins.sgi.SGIImageReaderSpi"},
|
||||
null,
|
||||
null,
|
||||
false, null, null, null, null,
|
||||
true, null, null, null, null
|
||||
);
|
||||
}
|
||||
}
|
@ -28,49 +28,21 @@
|
||||
|
||||
package com.twelvemonkeys.imageio.plugins.tga;
|
||||
|
||||
import com.twelvemonkeys.imageio.spi.ProviderInfo;
|
||||
import com.twelvemonkeys.imageio.util.IIOUtil;
|
||||
import com.twelvemonkeys.imageio.spi.ImageReaderSpiBase;
|
||||
|
||||
import javax.imageio.ImageReader;
|
||||
import javax.imageio.spi.ImageReaderSpi;
|
||||
import javax.imageio.stream.ImageInputStream;
|
||||
import java.io.IOException;
|
||||
import java.nio.ByteOrder;
|
||||
import java.util.Locale;
|
||||
|
||||
public final class TGAImageReaderSpi extends ImageReaderSpi {
|
||||
public final class TGAImageReaderSpi extends ImageReaderSpiBase {
|
||||
|
||||
/**
|
||||
* Creates a {@code TGAImageReaderSpi}.
|
||||
*/
|
||||
public TGAImageReaderSpi() {
|
||||
this(IIOUtil.getProviderInfo(TGAImageReaderSpi.class));
|
||||
}
|
||||
|
||||
private TGAImageReaderSpi(final ProviderInfo providerInfo) {
|
||||
super(
|
||||
providerInfo.getVendorName(),
|
||||
providerInfo.getVersion(),
|
||||
new String[]{
|
||||
"tga", "TGA",
|
||||
"targa", "TARGA"
|
||||
},
|
||||
new String[]{"tga", "tpic"},
|
||||
new String[]{
|
||||
// No official IANA record exists
|
||||
"image/tga", "image/x-tga",
|
||||
"image/targa", "image/x-targa",
|
||||
},
|
||||
"com.twelvemkonkeys.imageio.plugins.tga.TGAImageReader",
|
||||
new Class[] {ImageInputStream.class},
|
||||
null,
|
||||
true, // supports standard stream metadata
|
||||
null, null, // native stream format name and class
|
||||
null, null, // extra stream formats
|
||||
true, // supports standard image metadata
|
||||
null, null,
|
||||
null, null // extra image metadata formats
|
||||
);
|
||||
super(new TGAProviderInfo());
|
||||
}
|
||||
|
||||
@Override public boolean canDecodeInput(final Object source) throws IOException {
|
||||
|
@ -0,0 +1,34 @@
|
||||
package com.twelvemonkeys.imageio.plugins.tga;
|
||||
|
||||
import com.twelvemonkeys.imageio.spi.ReaderWriterProviderInfo;
|
||||
|
||||
/**
|
||||
* SGIProviderInfo.
|
||||
*
|
||||
* @author <a href="mailto:harald.kuhr@gmail.com">Harald Kuhr</a>
|
||||
* @author last modified by $Author: harald.kuhr$
|
||||
* @version $Id: SGIProviderInfo.java,v 1.0 20/03/15 harald.kuhr Exp$
|
||||
*/
|
||||
final class TGAProviderInfo extends ReaderWriterProviderInfo {
|
||||
protected TGAProviderInfo() {
|
||||
super(
|
||||
TGAProviderInfo.class,
|
||||
new String[]{
|
||||
"tga", "TGA",
|
||||
"targa", "TARGA"
|
||||
},
|
||||
new String[]{"tga", "tpic"},
|
||||
new String[]{
|
||||
// No official IANA record exists
|
||||
"image/tga", "image/x-tga",
|
||||
"image/targa", "image/x-targa",
|
||||
},
|
||||
"com.twelvemkonkeys.imageio.plugins.tga.TGAImageReader",
|
||||
new String[] {"com.twelvemonkeys.imageio.plugins.tga.TGAImageReaderSpi"},
|
||||
null,
|
||||
null,
|
||||
false, null, null, null, null,
|
||||
true, null, null, null, null
|
||||
);
|
||||
}
|
||||
}
|
@ -28,8 +28,7 @@
|
||||
|
||||
package com.twelvemonkeys.imageio.plugins.thumbsdb;
|
||||
|
||||
import com.twelvemonkeys.imageio.spi.ProviderInfo;
|
||||
import com.twelvemonkeys.imageio.util.IIOUtil;
|
||||
import com.twelvemonkeys.imageio.spi.ImageReaderSpiBase;
|
||||
import com.twelvemonkeys.io.ole2.CompoundDocument;
|
||||
|
||||
import javax.imageio.ImageReader;
|
||||
@ -48,36 +47,21 @@ import java.util.Locale;
|
||||
* @author <a href="mailto:harald.kuhr@gmail.com">Harald Kuhr</a>
|
||||
* @version $Id: ThumbsDBImageReaderSpi.java,v 1.0 28.feb.2006 19:21:05 haku Exp$
|
||||
*/
|
||||
public class ThumbsDBImageReaderSpi extends ImageReaderSpi {
|
||||
public class ThumbsDBImageReaderSpi extends ImageReaderSpiBase {
|
||||
private ImageReaderSpi jpegProvider;
|
||||
|
||||
/**
|
||||
* Creates a {@code ThumbsDBImageReaderSpi}.
|
||||
*/
|
||||
public ThumbsDBImageReaderSpi() {
|
||||
this(IIOUtil.getProviderInfo(ThumbsDBImageReaderSpi.class));
|
||||
}
|
||||
|
||||
private ThumbsDBImageReaderSpi(final ProviderInfo pProviderInfo) {
|
||||
super(
|
||||
pProviderInfo.getVendorName(),
|
||||
pProviderInfo.getVersion(),
|
||||
new String[]{"thumbs", "THUMBS", "Thumbs DB"},
|
||||
new String[]{"db"},
|
||||
new String[]{"image/x-thumbs-db", "application/octet-stream"}, // TODO: Check IANA et al...
|
||||
"com.twelvemonkeys.imageio.plugins.thumbsdb.ThumbsDBImageReader",
|
||||
new Class[] {ImageInputStream.class},
|
||||
null,
|
||||
true, null, null, null, null,
|
||||
true, null, null, null, null
|
||||
);
|
||||
super(new ThumbsDBProviderInfo());
|
||||
}
|
||||
|
||||
public boolean canDecodeInput(Object source) throws IOException {
|
||||
return source instanceof ImageInputStream && canDecode((ImageInputStream) source);
|
||||
}
|
||||
|
||||
public boolean canDecode(ImageInputStream pInput) throws IOException {
|
||||
public boolean canDecode(final ImageInputStream pInput) throws IOException {
|
||||
maybeInitJPEGProvider();
|
||||
// If this is a OLE 2 CompoundDocument, we could try...
|
||||
// TODO: How do we know it's thumbs.db format (structure), without reading quite a lot?
|
||||
|
@ -0,0 +1,27 @@
|
||||
package com.twelvemonkeys.imageio.plugins.thumbsdb;
|
||||
|
||||
import com.twelvemonkeys.imageio.spi.ReaderWriterProviderInfo;
|
||||
|
||||
/**
|
||||
* ThumbsDBProviderInfo.
|
||||
*
|
||||
* @author <a href="mailto:harald.kuhr@gmail.com">Harald Kuhr</a>
|
||||
* @author last modified by $Author: harald.kuhr$
|
||||
* @version $Id: ThumbsDBProviderInfo.java,v 1.0 20/03/15 harald.kuhr Exp$
|
||||
*/
|
||||
final class ThumbsDBProviderInfo extends ReaderWriterProviderInfo {
|
||||
protected ThumbsDBProviderInfo() {
|
||||
super(
|
||||
ThumbsDBProviderInfo.class,
|
||||
new String[]{"thumbs", "THUMBS", "Thumbs DB"},
|
||||
new String[]{"db"},
|
||||
new String[]{"image/x-thumbs-db", "application/octet-stream"}, // TODO: Check IANA et al...
|
||||
"com.twelvemonkeys.imageio.plugins.thumbsdb.ThumbsDBImageReader",
|
||||
new String[] {"com.twelvemonkeys.imageio.plugins.thumbsdb.ThumbsDBImageReaderSpi"},
|
||||
null,
|
||||
null,
|
||||
false, null, null, null, null,
|
||||
true, null, null, null, null
|
||||
);
|
||||
}
|
||||
}
|
@ -29,8 +29,7 @@
|
||||
package com.twelvemonkeys.imageio.plugins.tiff;
|
||||
|
||||
import com.twelvemonkeys.imageio.metadata.exif.TIFF;
|
||||
import com.twelvemonkeys.imageio.spi.ProviderInfo;
|
||||
import com.twelvemonkeys.imageio.util.IIOUtil;
|
||||
import com.twelvemonkeys.imageio.spi.ImageReaderSpiBase;
|
||||
|
||||
import javax.imageio.spi.ImageReaderSpi;
|
||||
import javax.imageio.spi.ServiceRegistry;
|
||||
@ -46,33 +45,12 @@ import java.util.Locale;
|
||||
* @author last modified by $Author: haraldk$
|
||||
* @version $Id: TIFFImageReaderSpi.java,v 1.0 08.05.12 15:14 haraldk Exp$
|
||||
*/
|
||||
public class TIFFImageReaderSpi extends ImageReaderSpi {
|
||||
public class TIFFImageReaderSpi extends ImageReaderSpiBase {
|
||||
/**
|
||||
* Creates a {@code TIFFImageReaderSpi}.
|
||||
*/
|
||||
public TIFFImageReaderSpi() {
|
||||
this(IIOUtil.getProviderInfo(TIFFImageReaderSpi.class));
|
||||
}
|
||||
|
||||
private TIFFImageReaderSpi(final ProviderInfo providerInfo) {
|
||||
super(
|
||||
providerInfo.getVendorName(),
|
||||
providerInfo.getVersion(),
|
||||
new String[] {"tiff", "TIFF"},
|
||||
new String[] {"tif", "tiff"},
|
||||
new String[] {
|
||||
"image/tiff", "image/x-tiff"
|
||||
},
|
||||
"com.twelvemkonkeys.imageio.plugins.tiff.TIFFImageReader",
|
||||
new Class[] {ImageInputStream.class},
|
||||
new String[] {"com.twelvemkonkeys.imageio.plugins.tif.TIFFImageWriterSpi"},
|
||||
true, // supports standard stream metadata
|
||||
null, null, // native stream format name and class
|
||||
null, null, // extra stream formats
|
||||
true, // supports standard image metadata
|
||||
null, null,
|
||||
null, null // extra image metadata formats
|
||||
);
|
||||
super(new TIFFProviderInfo());
|
||||
}
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
|
@ -28,13 +28,10 @@
|
||||
|
||||
package com.twelvemonkeys.imageio.plugins.tiff;
|
||||
|
||||
import com.twelvemonkeys.imageio.spi.ProviderInfo;
|
||||
import com.twelvemonkeys.imageio.util.IIOUtil;
|
||||
import com.twelvemonkeys.imageio.spi.ImageWriterSpiBase;
|
||||
|
||||
import javax.imageio.ImageTypeSpecifier;
|
||||
import javax.imageio.ImageWriter;
|
||||
import javax.imageio.spi.ImageWriterSpi;
|
||||
import javax.imageio.stream.ImageOutputStream;
|
||||
import java.io.IOException;
|
||||
import java.util.Locale;
|
||||
|
||||
@ -45,45 +42,27 @@ import java.util.Locale;
|
||||
* @author last modified by $Author: haraldk$
|
||||
* @version $Id: TIFFImageWriterSpi.java,v 1.0 18.09.13 12:46 haraldk Exp$
|
||||
*/
|
||||
public final class TIFFImageWriterSpi extends ImageWriterSpi {
|
||||
public final class TIFFImageWriterSpi extends ImageWriterSpiBase {
|
||||
// TODO: Implement canEncodeImage better
|
||||
|
||||
public TIFFImageWriterSpi() {
|
||||
this(IIOUtil.getProviderInfo(TIFFImageWriterSpi.class));
|
||||
}
|
||||
|
||||
private TIFFImageWriterSpi(final ProviderInfo providerInfo) {
|
||||
super(
|
||||
providerInfo.getVendorName(), providerInfo.getVersion(),
|
||||
new String[] {"tiff", "TIFF", "tif", "TIFF"},
|
||||
new String[] {"tif", "tiff"},
|
||||
new String[] {"image/tiff", "image/x-tiff"},
|
||||
"com.twelvemonkeys.imageio.plugins.tiff.TIFFImageWriter",
|
||||
new Class<?>[] {ImageOutputStream.class},
|
||||
new String[] {"com.twelvemonkeys.imageio.plugins.tiff.TIFFImageReaderSpi"},
|
||||
true, // supports standard stream metadata
|
||||
null, null, // native stream format name and class
|
||||
null, null, // extra stream formats
|
||||
true, // supports standard image metadata
|
||||
null, null,
|
||||
null, null // extra image metadata formats
|
||||
);
|
||||
super(new TIFFProviderInfo());
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean canEncodeImage(ImageTypeSpecifier type) {
|
||||
public boolean canEncodeImage(final ImageTypeSpecifier type) {
|
||||
// TODO: Test bit depths compatibility
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ImageWriter createWriterInstance(Object extension) throws IOException {
|
||||
public ImageWriter createWriterInstance(final Object extension) throws IOException {
|
||||
return new TIFFImageWriter(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getDescription(Locale locale) {
|
||||
public String getDescription(final Locale locale) {
|
||||
return "Aldus/Adobe Tagged Image File Format (TIFF) image writer";
|
||||
}
|
||||
}
|
||||
|
@ -0,0 +1,29 @@
|
||||
package com.twelvemonkeys.imageio.plugins.tiff;
|
||||
|
||||
import com.twelvemonkeys.imageio.spi.ReaderWriterProviderInfo;
|
||||
|
||||
/**
|
||||
* TIFFProviderInfo.
|
||||
*
|
||||
* @author <a href="mailto:harald.kuhr@gmail.com">Harald Kuhr</a>
|
||||
* @author last modified by $Author: harald.kuhr$
|
||||
* @version $Id: TIFFProviderInfo.java,v 1.0 20/03/15 harald.kuhr Exp$
|
||||
*/
|
||||
final class TIFFProviderInfo extends ReaderWriterProviderInfo {
|
||||
protected TIFFProviderInfo() {
|
||||
super(
|
||||
TIFFProviderInfo.class,
|
||||
new String[] {"tiff", "TIFF"},
|
||||
new String[] {"tif", "tiff"},
|
||||
new String[] {
|
||||
"image/tiff", "image/x-tiff"
|
||||
},
|
||||
"com.twelvemkonkeys.imageio.plugins.tiff.TIFFImageReader",
|
||||
new String[] {"com.twelvemonkeys.imageio.plugins.tiff.TIFFImageReaderSpi"},
|
||||
"com.twelvemonkeys.imageio.plugins.tiff.TIFFImageWriter",
|
||||
new String[] {"com.twelvemkonkeys.imageio.plugins.tif.TIFFImageWriterSpi"},
|
||||
false, null, null, null, null,
|
||||
true, null, null, null, null
|
||||
);
|
||||
}
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user