[][src]Function qr_code::ec::construct_codewords

pub fn construct_codewords(
    rawbits: &[u8],
    version: Version,
    ec_level: EcLevel
) -> QrResult<(Vec<u8>, Vec<u8>)>

Constructs data and error correction codewords ready to be put in the QR code matrix.

Errors

Returns Err(QrError::InvalidVersion) if it is not valid to use the ec_level for the given version (e.g. Version::Micro(1) with EcLevel::H).