glymur/jp2box.py
def write(self, fptr):
        """Write a channel definition box to file.
        """
        self._validate(writing=True)
        num_components = len(self.association)
        fptr.write(struct.pack('>I4s', 8 + 2 + num_components * 6, b'cdef'))
        fptr.write(struct.pack('>H', num_components))
        for j in range(num_components):
            fptr.write(struct.pack('>' + 'H' * 3,
                                   self.index[j],
                                   self.channel_type[j],
                                   self.association[j]))
Write a channel definition box to file.
        
Write a channel definition box to file.
Write a channel definition box to file .
def write(self, fptr):
        self._validate(writing=True)
        num_components = len(self.association)
        fptr.write(struct.pack('>I4s', 8 + 2 + num_components * 6, b'cdef'))
        fptr.write(struct.pack('>H', num_components))
        for j in range(num_components):
            fptr.write(struct.pack('>' + 'H' * 3,
                                   self.index[j],
                                   self.channel_type[j],
                                   self.association[j]))
def write ( self , fptr ) : self . _validate ( writing = True ) num_components = len ( self . association ) fptr . write ( struct . pack ( '>I4s' , 8 + 2 + num_components * 6 , b'cdef' ) ) fptr . write ( struct . pack ( '>H' , num_components ) ) for j in range ( num_components ) : fptr . write ( struct . pack ( '>' + 'H' * 3 , self . index [ j ] , self . channel_type [ j ] , self . association [ j ] ) )
Write a channel definition box to file.
Write a channel definition box to file .
"""Write a channel definition box to file.
        """
self
fptr