Class SoMRCImageRW
- java.lang.Object
-
- com.openinventor.inventor.Inventor
-
- com.openinventor.inventor.image.SoRasterImageRW
-
- com.openinventor.inventor.image.SoMRCImageRW
-
public class SoMRCImageRW extends SoRasterImageRW
Class for encoding and decoding an MRC raster image. This class is used for encoding and decoding a MRC raster image.MRC is a file format that has become industry standard in cryo-electron microscopy (cryoEM) and electron tomography (ET), where the result of the technique is a three-dimensional grid of voxels each with a value corresponding to electron density or electric potential. It was developed by the MRC (Medical Research Council, UK) Laboratory of Molecular Biology. In 2014, the format was standardised. The format specification is available on the CCP-EM website. For details see:
http://www.ccpem.ac.uk/mrc_format/mrc2014.php The writeCapability is WRITE_UNAVAILABLE and isMultipleBufferInverted is true.
See
SoRasterImageRW
for more information and code examples.NOTE: Class available since Open Inventor 10.4.
- See Also:
SoRasterImageFile
,SoRasterImageRW
,SbRasterImage
,SoVRMrcFileReader
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.openinventor.inventor.image.SoRasterImageRW
SoRasterImageRW.OpenModes, SoRasterImageRW.ReadCapabilities, SoRasterImageRW.WriteCapabilities
-
Nested classes/interfaces inherited from class com.openinventor.inventor.Inventor
Inventor.ConstructorCommand
-
-
Field Summary
-
Fields inherited from class com.openinventor.inventor.Inventor
VERBOSE_LEVEL, ZeroHandle
-
-
Constructor Summary
Constructors Constructor Description SoMRCImageRW()
Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
read(SbRasterImage rasterImage, long imageIndex)
Calls read(rasterImage, imageIndex, false).boolean
read(SbRasterImage rasterImage, long imageIndex, boolean infoOnly)
Read the current open image into rasterImage.boolean
readRegion(SbRasterImage rasterImage, long imageIndex, SbBox2i32 region)
Read the specified region of current open image into rasterImage.-
Methods inherited from class com.openinventor.inventor.image.SoRasterImageRW
checkRead, close, enableMultipleWriting, getReadCapability, getWriteCapability, isMultipleBufferInverted, isMultipleWritingEnabled, open, read, read, readRegion, write, write, write, writeFooter, writeHeader
-
Methods inherited from class com.openinventor.inventor.Inventor
dispose, getNativeResourceHandle
-
-
-
-
Method Detail
-
read
public boolean read(SbRasterImage rasterImage, long imageIndex)
Calls read(rasterImage, imageIndex, false).
-
readRegion
public boolean readRegion(SbRasterImage rasterImage, long imageIndex, SbBox2i32 region)
Read the specified region of current open image into rasterImage. Returns true if successful. Call the open() method before calling this method.After calling this method successfully, the size of the
SbRasterImage
is the requested region size. The requested region may extend outside the source image. In this case, undefined pixels are set to zero. The region may be as small as a single pixel, e.g. (1,1,1,1), but xmin must be <= xmax and ymin <= ymax.
-
read
public boolean read(SbRasterImage rasterImage, long imageIndex, boolean infoOnly)
Read the current open image into rasterImage. Returns true if successful. Call the open() method before calling this method.If infoOnly is true, then the buffer will not be read; the parameter rasterImage will be set with raster size and raster number of components, the buffer will be NULL.
-
-