M4_Utils.h revision 7c9d8018755adf1857571125ba1b3598c96ea506
1/* 2 * Copyright (C) 2004-2011 NXP Software 3 * Copyright (C) 2011 The Android Open Source Project 4 * 5 * Licensed under the Apache License, Version 2.0 (the "License"); 6 * you may not use this file except in compliance with the License. 7 * You may obtain a copy of the License at 8 * 9 * http://www.apache.org/licenses/LICENSE-2.0 10 * 11 * Unless required by applicable law or agreed to in writing, software 12 * distributed under the License is distributed on an "AS IS" BASIS, 13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 * See the License for the specific language governing permissions and 15 * limitations under the License. 16 */ 17/** 18************************************************************************* 19 * @file M4_Utils.h 20 * @brief Utilities 21 * @note This file defines utility macros 22************************************************************************* 23*/ 24#ifndef __M4_UTILS_H__ 25#define __M4_UTILS_H__ 26 27#ifdef __cplusplus 28extern "C" { 29#endif 30 31/* M4_MediaTime definition 32 This type is used internally by some shell components */ 33#include "M4OSA_Types.h" 34typedef M4OSA_Double M4_MediaTime; 35 36/* GET_MEMORY32 macro definition 37 This macro is used by the 3GP reader*/ 38#ifdef __BIG_ENDIAN 39#define GET_MEMORY32(x) (x) 40#else 41#define GET_MEMORY32(x) ( (((x)&0xff)<<24) | (((x)&0xff00)<<8) |\ 42 (((x)&0xff0000)>>8) | (((x)&0xff000000)>>24) ) 43#endif /*__BIG_ENDIAN*/ 44 45#ifdef __cplusplus 46} 47#endif 48 49#endif /* __M4_UTILS_H__*/ 50 51