Package autodesk_toxik :: Module media :: Class ImageFormat
[frames] | no frames]

Class ImageFormat

 object --+    
          |    
Boost.Python.instance --+
              |
             ImageFormat

Utility used to set image format of an image reader node, which is expressed in xml. This is a convenient class to modify any parameters of the image format without having to deal directly with xml.

Instance Methods
 
__init__(...)
Constructor takes an xml description of the format.
 
__reduce__(...)
helper for pickle
tuple
getAspectRatio(...)
Returns: A tuple as (numerator, denominator) representing the pixel aspect ratio.
int
getBitDepth(...)
Returns: An integer representing the bit depth.
int
getNbComponents(...)
Returns: An integer representing the number of components.
tuple
getRate(...)
Returns: A tuple as (numerator, denominator) representing the frame rate.
str
getXml(...)
Returns: A string representing the xml description of the image format.
 
setAspectRatio(...)
Sets the pixel aspect ratio.
 
setBitDepth(...)
Sets the bit depth.
 
setNbComponents(...)
Sets the number of components.
 
setRate(...)
Sets the frame rate as a (numerator, denominator) tuple.

Inherited from Boost.Python.instance: __new__

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Class Variables
  __instance_size__ = 40
Properties

Inherited from object: __class__

Method Details

__init__(...)
(Constructor)

 

Constructor takes an xml description of the format. If the string is empty, the format will default to the following values: aspect ratio= 1:1, nb components = 3, depth = 32 and rate = 24.

Parameters:
  • xml (str)
Overrides: object.__init__

__reduce__(...)

 

helper for pickle

Overrides: object.__reduce__
(inherited documentation)

getAspectRatio(...)

 
Returns: tuple
A tuple as (numerator, denominator) representing the pixel aspect ratio.

getBitDepth(...)

 
Returns: int
An integer representing the bit depth.

getNbComponents(...)

 
Returns: int
An integer representing the number of components.

getRate(...)

 
Returns: tuple
A tuple as (numerator, denominator) representing the frame rate.

getXml(...)

 
Returns: str
A string representing the xml description of the image format.

setAspectRatio(...)

 

Sets the pixel aspect ratio.

Parameters:
  • aspectRatio (tuple) - The pixel aspect ratio represented as a (numerator, denominator) integer tuple.

setBitDepth(...)

 

Sets the bit depth.

Parameters:
  • bitDepth (int)

setNbComponents(...)

 

Sets the number of components.

Parameters:
  • nbComponents (int)

setRate(...)

 

Sets the frame rate as a (numerator, denominator) tuple.

Parameters:
  • rate (tuple) - The frame rate represented as a (numerator, denominator) integer tuple.