libcdio  2.1.0
About: GNU libcdio is a library for CD-ROM and CD image access.
  Fossies Dox: libcdio-2.1.0.tar.bz2  ("inofficial" and yet experimental doxygen-generated source code documentation)  

types.h File Reference

Common type definitions used pervasively in libcdio. More...

#include <sys/types.h>
#include <stdint.h>
Include dependency graph for types.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  msf_s
 MSF (minute/second/frame) structure. More...
 
union  cdio_cdrom_addr
 

Macros

#define UINT16_C(c)   c ## U
 
#define UINT32_C(c)   c ## U
 
#define UINT64_C(c)   c ## ULL
 
#define INT64_C(c)   c ## LL
 
#define __bool_true_false_are_defined   1
 
#define bool   unsigned char
 
#define true   1
 
#define false   0
 
#define GNUC_PRINTF(format_idx, arg_idx)
 
#define GNUC_SCANF(format_idx, arg_idx)
 
#define GNUC_FORMAT(arg_idx)
 
#define GNUC_NORETURN
 
#define GNUC_CONST
 
#define GNUC_UNUSED
 
#define GNUC_PACKED
 
#define PRAGMA_BEGIN_PACKED
 
#define PRAGMA_END_PACKED
 
#define GNUC_LIKELY(x)   (x)
 
#define GNUC_UNLIKELY(x)   (x)
 
#define NULL   ((void*) 0)
 
#define LIBCDIO_DEPRECATED(object, notice)
 
#define __cd_offsetof(TYPE, MEMBER)   ((size_t) &((TYPE *)0)->MEMBER)
 
#define msf_t_SIZEOF   3
 
#define CDIO_INVALID_SESSION   0xFF
 
#define CDIO_INVALID_LBA   -45301
 
#define CDIO_INVALID_LSN   CDIO_INVALID_LBA
 
#define CDIO_MCN_SIZE   13
 
#define CDIO_ISRC_SIZE   12
 

Typedefs

typedef uint8_t ubyte
 
typedef struct msf_s msf_t
 
typedef char cdio_utf8_t
 UTF-8 char definition. More...
 
typedef uint8_t bitfield_t
 
typedef int32_t lba_t
 
typedef int32_t lsn_t
 
typedef uint8_t track_t
 
typedef uint8_t session_t
 
typedef char cdio_mcn_t[13+1]
 
typedef char cdio_isrc_t[12+1]
 
typedef int cdio_fs_anal_t
 
typedef void(* CdioDataFree_t) (void *ptr)
 

Enumerations

enum  bool_3way_t { nope = 0, yep = 1, dunno = 2 }
 
enum  cdio_track_flag {
  CDIO_TRACK_FLAG_NONE = 0x00, CDIO_TRACK_FLAG_PRE_EMPHASIS = 0x01, CDIO_TRACK_FLAG_COPY_PERMITTED = 0x02, CDIO_TRACK_FLAG_DATA = 0x04,
  CDIO_TRACK_FLAG_FOUR_CHANNEL_AUDIO = 0x08, CDIO_TRACK_FLAG_SCMS = 0x10
}
 

Detailed Description

Common type definitions used pervasively in libcdio.

Definition in file types.h.

Macro Definition Documentation

◆ __bool_true_false_are_defined

#define __bool_true_false_are_defined   1

Definition at line 110 of file types.h.

◆ __cd_offsetof

#define __cd_offsetof (   TYPE,
  MEMBER 
)    ((size_t) &((TYPE *)0)->MEMBER)

our own offsetof()-like macro

Definition at line 202 of file types.h.

◆ bool

#define bool   unsigned char

Definition at line 119 of file types.h.

◆ CDIO_INVALID_LBA

#define CDIO_INVALID_LBA   -45301

Constant for invalid LBA. It is 151 less than the most negative LBA -45150. This provide slack for the 150-frame offset in LBA to LSN 150 conversions

Definition at line 291 of file types.h.

◆ CDIO_INVALID_LSN

#define CDIO_INVALID_LSN   CDIO_INVALID_LBA

Constant for invalid LSN

Definition at line 296 of file types.h.

◆ CDIO_INVALID_SESSION

#define CDIO_INVALID_SESSION   0xFF

Constant for invalid session number

Definition at line 284 of file types.h.

◆ CDIO_ISRC_SIZE

#define CDIO_ISRC_SIZE   12

Number of ASCII bytes in International Standard Recording Codes (ISRC)

Definition at line 314 of file types.h.

◆ CDIO_MCN_SIZE

#define CDIO_MCN_SIZE   13

Number of ASCII bytes in a media catalog number (MCN). We include an extra 0 byte so these can be used as C strings.

Definition at line 302 of file types.h.

◆ false

#define false   0

Definition at line 122 of file types.h.

◆ GNUC_CONST

#define GNUC_CONST

Definition at line 149 of file types.h.

◆ GNUC_FORMAT

#define GNUC_FORMAT (   arg_idx)

Definition at line 147 of file types.h.

◆ GNUC_LIKELY

#define GNUC_LIKELY (   x)    (x)

Definition at line 179 of file types.h.

◆ GNUC_NORETURN

#define GNUC_NORETURN

Definition at line 148 of file types.h.

◆ GNUC_PACKED

Definition at line 151 of file types.h.

◆ GNUC_PRINTF

#define GNUC_PRINTF (   format_idx,
  arg_idx 
)

Definition at line 145 of file types.h.

◆ GNUC_SCANF

#define GNUC_SCANF (   format_idx,
  arg_idx 
)

Definition at line 146 of file types.h.

◆ GNUC_UNLIKELY

#define GNUC_UNLIKELY (   x)    (x)

Definition at line 180 of file types.h.

◆ GNUC_UNUSED

#define GNUC_UNUSED

Definition at line 150 of file types.h.

◆ INT64_C

#define INT64_C (   c)    c ## LL

Definition at line 102 of file types.h.

◆ LIBCDIO_DEPRECATED

#define LIBCDIO_DEPRECATED (   object,
  notice 
)

Provide a notice for deprecated elements. Before gcc 4.5 'deprecated' takes no arguments.

Definition at line 198 of file types.h.

◆ msf_t_SIZEOF

#define msf_t_SIZEOF   3

Definition at line 226 of file types.h.

◆ NULL

#define NULL   ((void*) 0)

Definition at line 184 of file types.h.

◆ PRAGMA_BEGIN_PACKED

#define PRAGMA_BEGIN_PACKED

Definition at line 168 of file types.h.

◆ PRAGMA_END_PACKED

#define PRAGMA_END_PACKED

Definition at line 169 of file types.h.

◆ true

#define true   1

Definition at line 121 of file types.h.

◆ UINT16_C

#define UINT16_C (   c)    c ## U

Definition at line 73 of file types.h.

◆ UINT32_C

#define UINT32_C (   c)    c ## U

Definition at line 82 of file types.h.

◆ UINT64_C

#define UINT64_C (   c)    c ## ULL

Definition at line 92 of file types.h.

Typedef Documentation

◆ bitfield_t

typedef uint8_t bitfield_t

Definition at line 251 of file types.h.

◆ cdio_fs_anal_t

typedef int cdio_fs_anal_t

Definition at line 322 of file types.h.

◆ cdio_isrc_t

typedef char cdio_isrc_t[12+1]

Type to hold ASCII bytes in a ISRC. We include an extra 0 byte so these can be used as C strings.

Definition at line 320 of file types.h.

◆ cdio_mcn_t

typedef char cdio_mcn_t[13+1]

Type to hold ASCII bytes in a media catalog number (MCN). We include an extra 0 byte so these can be used as C strings.

Definition at line 308 of file types.h.

◆ cdio_utf8_t

typedef char cdio_utf8_t

UTF-8 char definition.

Type to denote UTF-8 strings.

Definition at line 234 of file types.h.

◆ CdioDataFree_t

typedef void(* CdioDataFree_t) (void *ptr)

Definition at line 340 of file types.h.

◆ lba_t

typedef int32_t lba_t

The type of a Logical Block Address. We allow for an lba to be negative to be consistent with an lba, although I'm not sure this this is possible.

Definition at line 259 of file types.h.

◆ lsn_t

typedef int32_t lsn_t

The type of a Logical Sector Number. Note that an lba can be negative and the MMC3 specs allow for a conversion of a negative lba.

See also
msf_t

Definition at line 266 of file types.h.

◆ msf_t

typedef struct msf_s msf_t

Definition at line 224 of file types.h.

◆ session_t

typedef uint8_t session_t

The type of a session number 0..99.

Definition at line 279 of file types.h.

◆ track_t

typedef uint8_t track_t

The type of a track number 0..99.

Definition at line 276 of file types.h.

◆ ubyte

typedef uint8_t ubyte

Definition at line 51 of file types.h.

Enumeration Type Documentation

◆ bool_3way_t

Enumerator
nope 
yep 
dunno 

Definition at line 236 of file types.h.

◆ cdio_track_flag

track flags Q Sub-channel Control Field (4.2.3.3)

Enumerator
CDIO_TRACK_FLAG_NONE 

no flags set

CDIO_TRACK_FLAG_PRE_EMPHASIS 

audio track recorded with pre-emphasis

CDIO_TRACK_FLAG_COPY_PERMITTED 

digital copy permitted

CDIO_TRACK_FLAG_DATA 

data track

CDIO_TRACK_FLAG_FOUR_CHANNEL_AUDIO 

4 audio channels

CDIO_TRACK_FLAG_SCMS 

SCMS (5.29.2.7)

Definition at line 328 of file types.h.