libgpac
Documentation of the core library of GPAC
base64 encoding

Base 16 and 64 coding. More...

+ Collaboration diagram for base64 encoding:

Functions

u32 gf_base64_encode (const u8 *in_buffer, u32 in_buffer_size, u8 *out_buffer, u32 out_buffer_size)
 base64 encoder More...
 
u32 gf_base64_decode (u8 *in_buffer, u32 in_buffer_size, u8 *out_buffer, u32 out_buffer_size)
 base64 decoder More...
 
u32 gf_base16_encode (u8 *in_buffer, u32 in_buffer_size, u8 *out_buffer, u32 out_buffer_size)
 base16 encoder More...
 
u32 gf_base16_decode (u8 *in_buffer, u32 in_buffer_size, u8 *out_buffer, u32 out_buffer_size)
 base16 decoder More...
 

Detailed Description

This section documents the base encoding and decoding functions of the GPAC framework.

Function Documentation

◆ gf_base64_encode()

u32 gf_base64_encode ( const u8 in_buffer,
u32  in_buffer_size,
u8 out_buffer,
u32  out_buffer_size 
)

Encodes a data buffer to Base64

Parameters
in_bufferinput data buffer
in_buffer_sizeinput data buffer size
out_bufferoutput Base64 buffer location
out_buffer_sizeoutput Base64 buffer allocated size
Returns
size of the encoded Base64 buffer, 0 if error
Note
the encoded data buffer is not NULL-terminated.

◆ gf_base64_decode()

u32 gf_base64_decode ( u8 in_buffer,
u32  in_buffer_size,
u8 out_buffer,
u32  out_buffer_size 
)

Decodes a Base64 buffer to data

Parameters
in_bufferinput Base64 buffer
in_buffer_sizeinput Base64 buffer size
out_bufferoutput data buffer location
out_buffer_sizeoutput data buffer allocated size
Returns
size of the decoded buffer

◆ gf_base16_encode()

u32 gf_base16_encode ( u8 in_buffer,
u32  in_buffer_size,
u8 out_buffer,
u32  out_buffer_size 
)

Encodes a data buffer to Base16

Parameters
in_bufferinput data buffer
in_buffer_sizeinput data buffer size
out_bufferoutput Base16 buffer location
out_buffer_sizeoutput Base16 buffer allocated size
Returns
size of the encoded Base16 buffer, 0 if error
Note
the encoded data buffer is not NULL-terminated.

◆ gf_base16_decode()

u32 gf_base16_decode ( u8 in_buffer,
u32  in_buffer_size,
u8 out_buffer,
u32  out_buffer_size 
)

Decodes a Base16 buffer to data

Parameters
in_bufferinput Base16 buffer
in_buffer_sizeinput Base16 buffer size
out_bufferoutput data buffer location
out_buffer_sizeoutput data buffer allocated size
Returns
size of the decoded buffer