pub fn decode_base64_image(input: &str) -> Result<(Vec<u8>, Option<String>)>Expand description
Decode a base64 data URI or raw base64 string to bytes.
Handles formats:
data:image/png;base64,iVBOR...iVBOR...(raw base64)
Enforces a size limit (default 30 MB base64 input) to prevent OOM. Uses a tolerant decoder that accepts both padded and unpadded base64.