OpenImageSpec (object)

The OpenImageSpec represents a specification of an image within OpenImageIO. An OpenImageSpec is used when constructing an OpenImageOutput or reading from an OpenImageInput.

注釈

Please refer to the official OpenImageIO documentation for more details (https://sites.google.com/site/openimageio/documentation).

OpenImageSpec OpenImageSpec OpenImageSpec

/*
** Example: OpenImageSpec
*/

require OpenImageIO;
require FileIO;

operator entry() {

  FilePath path = FilePath('${TEMP}/test.jpg').expandEnvVars();

  OpenImageSpec spec(512, 512, 3, OpenImageTypeDescTypeColor());

  // writes a purely black image, 512x512 with 3 channels
  OpenImageOutput img();
  img.create(path.string());
  img.open(path.string(), spec);
  img.close();

  report(path.exists());
  report('Written image '+path.string());
}

/*
** Output:

true
Written image R:\Temp/test.jpg

*/

Methods

  OpenImageSpec ( in OpenImageSpec other )
  OpenImageSpec ( in OpenImageTypeDesc fmt )
  OpenImageSpec ( in SInt32 xres, in SInt32 yres, in SInt32 nchans, in OpenImageTypeDesc fmt )
  OpenImageSpec ()
  attribute ? ( in String name, in Float32 value )
  attribute ? ( in String name, in OpenImageTypeDesc fmt, in Data value )
  attribute ? ( in String name, in OpenImageTypeDesc fmt, in String value )
  attribute ? ( in String name, in SInt32 value )
  attribute ? ( in String name, in String value )
  attribute ? ( in String name, in UInt32 value )
  auto_stride ? ( io SInt64 xstride, in OpenImageTypeDesc format, in SInt32 nchannels )
  auto_stride ? ( io SInt64 xstride, io SInt64 ystride, io SInt64 zstride, in OpenImageTypeDesc format, in SInt32 nchannels, in SInt32 width, in SInt32 height )
  auto_stride ? ( io SInt64 xstride, io SInt64 ystride, io SInt64 zstride, in SInt64 channelsize, in SInt32 nchannels, in SInt32 width, in SInt32 height )
UInt64 channel_bytes ? ( in SInt32 chan, in Boolean native )
UInt64 channel_bytes ? ()
OpenImageTypeDesc channelformat ? ( in SInt32 chan )
OpenImageTypeDesc[] channelformats ? ()
String[] channelnames ? ()
OpenImageSpec clone ? ()
  default_channel_names ? ()
  erase_attribute ? ( in String name, in Boolean casesensitive )
  erase_attribute ? ( in String name, in OpenImageTypeDesc searchtype, in Boolean casesensitive )
OpenImageTypeDesc format ? ()
  from_xml ? ( in String xml )
SInt32 get_alpha_channel ? ()
Boolean get_deep ? ()
SInt32 get_depth ? ()
Float32 get_float_attribute ? ( in String name, in Float32 defaultval )
SInt32 get_full_depth ? ()
SInt32 get_full_height ? ()
SInt32 get_full_width ? ()
SInt32 get_full_x ? ()
SInt32 get_full_y ? ()
SInt32 get_full_z ? ()
SInt32 get_height ? ()
SInt32 get_int_attribute ? ( in String name, in SInt32 defaultval )
SInt32 get_nchannels ? ()
String get_string_attribute ? ( in String name, in String defaultval )
SInt32 get_tile_depth ? ()
SInt32 get_tile_height ? ()
SInt32 get_tile_width ? ()
SInt32 get_width ? ()
SInt32 get_x ? ()
SInt32 get_y ? ()
SInt32 get_z ? ()
SInt32 get_z_channel ? ()
UInt64 image_bytes ? ( in Boolean native )
UInt64 image_pixels ? ()
UInt64 pixel_bytes ? ( in Boolean native )
UInt64 pixel_bytes ? ( in SInt32 chbegin, in SInt32 chend, in Boolean native )
  reset ! ()
UInt64 scanline_bytes ? ( in Boolean native )
  set_alpha_channel ? ( in SInt32 value )
  set_deep ? ( in Boolean value )
  set_depth ? ( in SInt32 value )
  set_format ? ( in OpenImageTypeDesc fmt )
  set_full_depth ? ( in SInt32 value )
  set_full_height ? ( in SInt32 value )
  set_full_width ? ( in SInt32 value )
  set_full_x ? ( in SInt32 value )
  set_full_y ? ( in SInt32 value )
  set_full_z ? ( in SInt32 value )
  set_height ? ( in SInt32 value )
  set_nchannels ? ( in SInt32 value )
  set_tile_depth ? ( in SInt32 value )
  set_tile_height ? ( in SInt32 value )
  set_tile_width ? ( in SInt32 value )
  set_width ? ( in SInt32 value )
  set_x ? ( in SInt32 value )
  set_y ? ( in SInt32 value )
  set_z ? ( in SInt32 value )
  set_z_channel ? ( in SInt32 value )
  setchannelnames ? ( in String names[] )
Boolean size_t_safe ? ()
UInt64 tile_bytes ? ( in Boolean native )
UInt64 tile_pixels ? ()
String to_xml ? ()
Boolean valid_tile_range ? ( in SInt32 xbegin, in SInt32 xend, in SInt32 ybegin, in SInt32 yend, in SInt32 zbegin, in SInt32 zend )
  ~OpenImageSpec ()

Methods in detail

OpenImageSpec ( in OpenImageSpec other )

copy constructor


OpenImageSpec ( in OpenImageTypeDesc fmt )


OpenImageSpec ( in SInt32 xres, in SInt32 yres, in SInt32 nchans, in OpenImageTypeDesc fmt )


OpenImageSpec ()


OpenImageSpec.attribute? ( in String name, in Float32 value )


OpenImageSpec.attribute? ( in String name, in OpenImageTypeDesc fmt, in Data value )


OpenImageSpec.attribute? ( in String name, in OpenImageTypeDesc fmt, in String value )


OpenImageSpec.attribute? ( in String name, in SInt32 value )


OpenImageSpec.attribute? ( in String name, in String value )


OpenImageSpec.attribute? ( in String name, in UInt32 value )


OpenImageSpec.auto_stride? ( io SInt64 xstride, in OpenImageTypeDesc format, in SInt32 nchannels )


OpenImageSpec.auto_stride? ( io SInt64 xstride, io SInt64 ystride, io SInt64 zstride, in OpenImageTypeDesc format, in SInt32 nchannels, in SInt32 width, in SInt32 height )


OpenImageSpec.auto_stride? ( io SInt64 xstride, io SInt64 ystride, io SInt64 zstride, in SInt64 channelsize, in SInt32 nchannels, in SInt32 width, in SInt32 height )


UInt64 OpenImageSpec.channel_bytes? ( in SInt32 chan, in Boolean native )


UInt64 OpenImageSpec.channel_bytes? ()


OpenImageTypeDesc OpenImageSpec.channelformat? ( in SInt32 chan )


OpenImageTypeDesc[] OpenImageSpec.channelformats? ()


String[] OpenImageSpec.channelnames? ()


OpenImageSpec OpenImageSpec.clone? ()

clone method


OpenImageSpec.default_channel_names? ()


OpenImageSpec.erase_attribute? ( in String name, in Boolean casesensitive )


OpenImageSpec.erase_attribute? ( in String name, in OpenImageTypeDesc searchtype, in Boolean casesensitive )


OpenImageTypeDesc OpenImageSpec.format? ()


OpenImageSpec.from_xml? ( in String xml )


SInt32 OpenImageSpec.get_alpha_channel? ()


Boolean OpenImageSpec.get_deep? ()


SInt32 OpenImageSpec.get_depth? ()


Float32 OpenImageSpec.get_float_attribute? ( in String name, in Float32 defaultval )


SInt32 OpenImageSpec.get_full_depth? ()


SInt32 OpenImageSpec.get_full_height? ()


SInt32 OpenImageSpec.get_full_width? ()


SInt32 OpenImageSpec.get_full_x? ()


SInt32 OpenImageSpec.get_full_y? ()


SInt32 OpenImageSpec.get_full_z? ()


SInt32 OpenImageSpec.get_height? ()


SInt32 OpenImageSpec.get_int_attribute? ( in String name, in SInt32 defaultval )


SInt32 OpenImageSpec.get_nchannels? ()


String OpenImageSpec.get_string_attribute? ( in String name, in String defaultval )


SInt32 OpenImageSpec.get_tile_depth? ()


SInt32 OpenImageSpec.get_tile_height? ()


SInt32 OpenImageSpec.get_tile_width? ()


SInt32 OpenImageSpec.get_width? ()


SInt32 OpenImageSpec.get_x? ()


SInt32 OpenImageSpec.get_y? ()


SInt32 OpenImageSpec.get_z? ()


SInt32 OpenImageSpec.get_z_channel? ()


UInt64 OpenImageSpec.image_bytes? ( in Boolean native )


UInt64 OpenImageSpec.image_pixels? ()


UInt64 OpenImageSpec.pixel_bytes? ( in Boolean native )


UInt64 OpenImageSpec.pixel_bytes? ( in SInt32 chbegin, in SInt32 chend, in Boolean native )


OpenImageSpec.reset! ()


UInt64 OpenImageSpec.scanline_bytes? ( in Boolean native )


OpenImageSpec.set_alpha_channel? ( in SInt32 value )


OpenImageSpec.set_deep? ( in Boolean value )


OpenImageSpec.set_depth? ( in SInt32 value )


OpenImageSpec.set_format? ( in OpenImageTypeDesc fmt )


OpenImageSpec.set_full_depth? ( in SInt32 value )


OpenImageSpec.set_full_height? ( in SInt32 value )


OpenImageSpec.set_full_width? ( in SInt32 value )


OpenImageSpec.set_full_x? ( in SInt32 value )


OpenImageSpec.set_full_y? ( in SInt32 value )


OpenImageSpec.set_full_z? ( in SInt32 value )


OpenImageSpec.set_height? ( in SInt32 value )


OpenImageSpec.set_nchannels? ( in SInt32 value )


OpenImageSpec.set_tile_depth? ( in SInt32 value )


OpenImageSpec.set_tile_height? ( in SInt32 value )


OpenImageSpec.set_tile_width? ( in SInt32 value )


OpenImageSpec.set_width? ( in SInt32 value )


OpenImageSpec.set_x? ( in SInt32 value )


OpenImageSpec.set_y? ( in SInt32 value )


OpenImageSpec.set_z? ( in SInt32 value )


OpenImageSpec.set_z_channel? ( in SInt32 value )


OpenImageSpec.setchannelnames? ( in String names[] )


Boolean OpenImageSpec.size_t_safe? ()


UInt64 OpenImageSpec.tile_bytes? ( in Boolean native )


UInt64 OpenImageSpec.tile_pixels? ()


String OpenImageSpec.to_xml? ()


Boolean OpenImageSpec.valid_tile_range? ( in SInt32 xbegin, in SInt32 xend, in SInt32 ybegin, in SInt32 yend, in SInt32 zbegin, in SInt32 zend )


~ OpenImageSpec ()