congrats Icon
New! Announcing Tabnine Chat Beta
Learn More
Tabnine Logo
loci.formats.codec
Code IndexAdd Tabnine to your IDE (free)

How to use loci.formats.codec

Best Java code snippets using loci.formats.codec (Showing top 20 results out of 315)

origin: openmicroscopy/bioformats

/** Creates a new instance. */
public JPEG2000Writer() {
 super("JPEG-2000", "jp2");
 compressionTypes = new String[] {CompressionType.J2K_LOSSY.getCompression(), 
   CompressionType.J2K.getCompression()};
 //The default codec options
 options = JPEG2000CodecOptions.getDefaultOptions();
}
origin: ome/formats-bsd

/** Return JPEG2000CodecOptions with reasonable default values. */
public static JPEG2000CodecOptions getDefaultOptions() {
 CodecOptions options = CodecOptions.getDefaultOptions();
 return getDefaultOptions(options);
}
origin: openmicroscopy/bioformats

/** Return CodecOptions with reasonable default values. */
public static CodecOptions getDefaultOptions() {
 CodecOptions options = new CodecOptions();
 options.littleEndian = false;
 options.interleaved = false;
 options.lossless = true;
 options.ycbcr = false;
 return options;
}
origin: ome/formats-gpl

private Codec createCodec(boolean isJPEG) {
 return isJPEG ? new JPEG2000Codec() : new ZlibCodec();
}
origin: openmicroscopy/bioformats

@Deprecated
public int getSample(BitBuffer bb, CodecOptions options)
 throws FormatException
{
 try {
  return ((ome.codecs.HuffmanCodec) this.codec).getSample(bb.getWrapped(), getOptions(options));
 }
 catch(ome.codecs.CodecException e) {
  throw WrappedCodec.unwrapCodecException(e);
 }
}
origin: ome/formats-bsd

public OMEXMLWriter() {
 super("OME-XML", new String[] {"ome", "ome.xml"});
 compressionTypes =
  new String[] {CompressionType.UNCOMPRESSED.getCompression(),
   CompressionType.ZLIB.getCompression()};
 compression = compressionTypes[0];
}
origin: ome/formats-bsd

 public int getSample(RandomAccessInputStream bb, CodecOptions options)
  throws FormatException
 {
  try {
   return ((ome.codecs.HuffmanCodec) this.codec).getSample(bb, getOptions(options));
  }
  catch(ome.codecs.CodecException e) {
   throw WrappedCodec.unwrapCodecException(e);
  }
 }
}
origin: ome/formats-bsd

@Override
public byte[] decompress(byte[] data) throws FormatException {
 return decompress(data, null);
}
origin: ome/formats-bsd

/**
 * Return JPEG2000CodecOptions using the given CodecOptions as the default.
 * @param options The specified options.
 */
public static JPEG2000CodecOptions getDefaultOptions(CodecOptions options) {
 JPEG2000CodecOptions j2kOptions = new JPEG2000CodecOptions(options);
 j2kOptions.quality = j2kOptions.lossless ? Double.MAX_VALUE : 10;
 j2kOptions.codeBlockSize = new int[] {64, 64};
 j2kOptions.writeBox = true;
 return j2kOptions;
}
origin: ome/formats-bsd

/** Creates a new instance. */
public JPEG2000Writer() {
 super("JPEG-2000", "jp2");
 compressionTypes = new String[] {CompressionType.J2K_LOSSY.getCompression(), 
   CompressionType.J2K.getCompression()};
 //The default codec options
 options = JPEG2000CodecOptions.getDefaultOptions();
}
origin: openmicroscopy/bioformats

/** Return JPEG2000CodecOptions with reasonable default values. */
public static JPEG2000CodecOptions getDefaultOptions() {
 CodecOptions options = CodecOptions.getDefaultOptions();
 return getDefaultOptions(options);
}
origin: openmicroscopy/bioformats

private Codec createCodec(boolean isJPEG) {
 return isJPEG ? new JPEG2000Codec() : new ZlibCodec();
}
origin: ome/formats-api

/** Return CodecOptions with reasonable default values. */
public static CodecOptions getDefaultOptions() {
 CodecOptions options = new CodecOptions();
 options.littleEndian = false;
 options.interleaved = false;
 options.lossless = true;
 options.ycbcr = false;
 return options;
}
origin: ome/formats-bsd

@Deprecated
public int getSample(BitBuffer bb, CodecOptions options)
 throws FormatException
{
 try {
  return ((ome.codecs.HuffmanCodec) this.codec).getSample(bb.getWrapped(), getOptions(options));
 }
 catch(ome.codecs.CodecException e) {
  throw WrappedCodec.unwrapCodecException(e);
 }
}
origin: openmicroscopy/bioformats

public OMEXMLWriter() {
 super("OME-XML", new String[] {"ome", "ome.xml"});
 compressionTypes =
  new String[] {CompressionType.UNCOMPRESSED.getCompression(),
   CompressionType.ZLIB.getCompression()};
 compression = compressionTypes[0];
}
origin: openmicroscopy/bioformats

 public int getSample(RandomAccessInputStream bb, CodecOptions options)
  throws FormatException
 {
  try {
   return ((ome.codecs.HuffmanCodec) this.codec).getSample(bb, getOptions(options));
  }
  catch(ome.codecs.CodecException e) {
   throw WrappedCodec.unwrapCodecException(e);
  }
 }
}
origin: openmicroscopy/bioformats

@Override
public byte[] decompress(byte[][] data) throws FormatException {
 return decompress(data, null);
}
origin: openmicroscopy/bioformats

/**
 * Return JPEG2000CodecOptions using the given CodecOptions as the default.
 * @param options The specified options.
 */
public static JPEG2000CodecOptions getDefaultOptions(CodecOptions options) {
 JPEG2000CodecOptions j2kOptions = new JPEG2000CodecOptions(options);
 j2kOptions.quality = j2kOptions.lossless ? Double.MAX_VALUE : 10;
 j2kOptions.codeBlockSize = new int[] {64, 64};
 j2kOptions.writeBox = true;
 return j2kOptions;
}
origin: ome/formats-bsd

@Override
public byte[] decompress(byte[][] data) throws FormatException {
 return decompress(data, null);
}
origin: openmicroscopy/bioformats

@Override
public byte[] decompress(byte[] data) throws FormatException {
 return decompress(data, null);
}
loci.formats.codec

Most used classes

  • JPEG2000CodecOptions
    Options for compressing and decompressing JPEG-2000 data.
  • CodecOptions
    Options for compressing and decompressing data.
  • CompressionType
    An enumeration of compression types.
  • BitWriter
    A class for writing arbitrary numbers of bits to a byte array.
  • Codec
    This class is an interface for any kind of compression or decompression. Data is presented to the co
  • JPEG2000Codec,
  • JPEGCodec,
  • JPEGTileDecoder,
  • NikonCodecOptions,
  • PackbitsCodec,
  • ZlibCodec,
  • Base64Codec,
  • BaseCodec,
  • BitBuffer,
  • HuffmanCodec,
  • HuffmanCodecOptions,
  • JPEG2000SegmentMarker,
  • JPEGXRCodec,
  • LZOCodec
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now