code: def cio_open(cinfo, src=None):
      
      argtypes = [ctypes.POINTER(CommonStructType), ctypes.c_char_p,
                  ctypes.c_int]
      OPENJPEG.opj_cio_open.argtypes = argtypes
      OPENJPEG.opj_cio_open.restype = ctypes.POINTER(CioType)
  
      if src is None:
          length = 0
      else:
          length = len(src)
  
      cio = OPENJPEG.opj_cio_open(ctypes.cast(cinfo,
                                              ctypes.POINTER(CommonStructType)),
                                  src,
                                  length)
      return cio
docs: Wrapper for openjpeg library function opj_cio_open.