Changeset 4495:586bd2e28021 in roaraudio


Ignore:
Timestamp:
10/12/10 20:19:10 (14 years ago)
Author:
phi
Branch:
default
Phase:
public
Message:

added some basic macros

File:
1 edited

Legend:

Unmodified
Added
Removed
  • include/roaraudio/caps.h

    r4494 r4495  
    3030#define _ROARAUDIO_CAPS_H_ 
    3131 
     32// cap flags: 
     33#define ROAR_CF_REQUEST          0x0001 
     34 
     35// cap types: 
     36#define ROAR_CT_CAPS             0 
     37#define ROAR_CT_STANDARDS        1 
     38 
     39// standard vendors: 
     40#define ROAR_STDV_ROARAUDIO      0 
     41#define ROAR_STDV_PROTO          1 
     42#define ROAR_STDV_RFC            2 
     43 
     44// data macros for standards: 
     45#define ROAR_STD_MASK_VENDOR     0xFF000000 
     46#define ROAR_STD_MASK_STD        0x00FFFF00 
     47#define ROAR_STD_MASK_VERSION    0x000000FF 
     48 
     49#define ROAR_STD_MAKE(vendor,standard,version) ((((vendor)   & 0x00FF) << 24) | \ 
     50                                                (((standard) & 0xFFFF) <<  8) | \ 
     51                                                 ((version)  & 0x00FF)        ) 
     52 
     53#define ROAR_STD_VENDOR(x)  (((x) & ROAR_STD_MASK_VENDOR) >> 24) 
     54#define ROAR_STD_STD(x)     (((x) & ROAR_STD_MASK_STD)    >>  8) 
     55#define ROAR_STD_VERSION(x) ( (x) & ROAR_STD_MASK_VERSION      ) 
     56 
    3257#endif 
    3358 
Note: See TracChangeset for help on using the changeset viewer.