libgpac
Documentation of the core library of GPAC
setup.h File Reference

Base data types of GPAC. More...

#include <gpac/configuration.h>
#include <stdio.h>
#include <stdint.h>
#include <stdlib.h>
#include <stddef.h>
#include <stdarg.h>
#include <limits.h>
#include <float.h>
#include <ctype.h>
#include <string.h>
#include <assert.h>
+ Include dependency graph for setup.h:
+ This graph shows which files directly or indirectly include this file:

Data Structures

struct  GF_Fraction
 
struct  GF_Fraction64
 

Macros

#define _FILE_OFFSET_BITS   64
 
#define _LARGEFILE_SOURCE
 
#define _LARGEFILE64_SOURCE
 
#define GPAC_HAS_FD
 
#define GFINLINE   inline
 
#define stricmp   strcasecmp
 
#define strnicmp   strncasecmp
 
#define strupr   my_str_upr
 
#define strlwr   my_str_lwr
 
#define GF_PATH_SEPARATOR   '/'
 
#define GF_MAX_PATH   1023
 
#define GF_MAX_DOUBLE   DBL_MAX
 
#define GF_MIN_DOUBLE   -GF_MAX_DOUBLE
 
#define GF_MAX_FLOAT   FLT_MAX
 
#define GF_MIN_FLOAT   -GF_MAX_FLOAT
 
#define GF_EPSILON_FLOAT   FLT_EPSILON
 
#define GF_SHORT_MAX   SHRT_MAX
 
#define GF_SHORT_MIN   SHRT_MIN
 
#define GF_UINT_MAX   UINT_MAX
 
#define GF_INT_MAX   INT_MAX
 
#define GF_INT_MIN   INT_MIN
 
#define GF_UINT64_MAX   ULLONG_MAX
 
#define GF_INT64_MAX   LLONG_MAX
 
#define GF_INT64_MIN   LLONG_MIN
 
#define MIN(X, Y)   ((X)<(Y)?(X):(Y))
 
#define MAX(X, Y)   ((X)>(Y)?(X):(Y))
 
#define ABSDIFF(a, b)   ( ( (a) > (b) ) ? ((a) - (b)) : ((b) - (a)) )
 
#define ABS(a)   ( ( (a) > 0 ) ? (a) : - (a) )
 
#define LLD_SUF   "lld"
 
#define LLU_SUF   "llu"
 
#define LLX_SUF   "llx"
 
#define PTR_TO_U_CAST   (u32)
 
#define LLD   "%" LLD_SUF
 
#define LLU   "%" LLU_SUF
 
#define LLX   "%" LLX_SUF
 
#define GF_EXPORT
 
#define GPAC_ENABLE_DEBUG
 

Typedefs

typedef uint64_t u64
 
typedef int64_t s64
 
typedef uint32_t u32
 
typedef int32_t s32
 
typedef uint16_t u16
 
typedef int16_t s16
 
typedef uint8_t u8
 
typedef int8_t s8
 
typedef double Double
 
typedef float Float
 
typedef u8 bin128[16]
 

Enumerations

enum  Bool { GF_FALSE = 0 , GF_TRUE }
 

Functions

char * my_str_upr (char *str)
 
char * my_str_lwr (char *str)
 
void gf_free (void *ptr)
 
void * gf_malloc (size_t size)
 
void * gf_calloc (size_t num, size_t size_of)
 
char * gf_strdup (const char *str)
 
void * gf_realloc (void *ptr, size_t size)
 
size_t gf_strlcpy (char *dst, const char *src, size_t dsize)
 

Detailed Description

This file contains the base data types of GPAC, depending on the platform.

Macro Definition Documentation

◆ GPAC_ENABLE_DEBUG

#define GPAC_ENABLE_DEBUG

Macro for detecting debug configurations

Function Documentation

◆ gf_strlcpy()

size_t gf_strlcpy ( char *  dst,
const char *  src,
size_t  dsize 
)

copy source string to destination, ensuring 0-terminated string result

Parameters
dstdestination buffer
srcsource buffer
dsizesize of destination buffer
Returns
same as strlcpy
+ Here is the caller graph for this function: