102f5b5447de349216a40086ca6061efefb5a3025James Dong/* ------------------------------------------------------------------
202f5b5447de349216a40086ca6061efefb5a3025James Dong * Copyright (C) 1998-2009 PacketVideo
302f5b5447de349216a40086ca6061efefb5a3025James Dong *
402f5b5447de349216a40086ca6061efefb5a3025James Dong * Licensed under the Apache License, Version 2.0 (the "License");
502f5b5447de349216a40086ca6061efefb5a3025James Dong * you may not use this file except in compliance with the License.
602f5b5447de349216a40086ca6061efefb5a3025James Dong * You may obtain a copy of the License at
702f5b5447de349216a40086ca6061efefb5a3025James Dong *
802f5b5447de349216a40086ca6061efefb5a3025James Dong *      http://www.apache.org/licenses/LICENSE-2.0
902f5b5447de349216a40086ca6061efefb5a3025James Dong *
1002f5b5447de349216a40086ca6061efefb5a3025James Dong * Unless required by applicable law or agreed to in writing, software
1102f5b5447de349216a40086ca6061efefb5a3025James Dong * distributed under the License is distributed on an "AS IS" BASIS,
1202f5b5447de349216a40086ca6061efefb5a3025James Dong * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
1302f5b5447de349216a40086ca6061efefb5a3025James Dong * express or implied.
1402f5b5447de349216a40086ca6061efefb5a3025James Dong * See the License for the specific language governing permissions
1502f5b5447de349216a40086ca6061efefb5a3025James Dong * and limitations under the License.
1602f5b5447de349216a40086ca6061efefb5a3025James Dong * -------------------------------------------------------------------$
1702f5b5447de349216a40086ca6061efefb5a3025James Dong */
1802f5b5447de349216a40086ca6061efefb5a3025James Dong
1902f5b5447de349216a40086ca6061efefb5a3025James Dong#ifndef M4V_H263_DECODER_PV_TYPES_H_
2002f5b5447de349216a40086ca6061efefb5a3025James Dong#define M4V_H263_DECODER_PV_TYPES_H_
2102f5b5447de349216a40086ca6061efefb5a3025James Dong
2202f5b5447de349216a40086ca6061efefb5a3025James Dong#include <stdint.h>
2302f5b5447de349216a40086ca6061efefb5a3025James Dong#include <string.h>
244d0e827d0be6085893428b420ec5800f1973a43bJames Dong#include <stdlib.h> // for free, malloc, etc
2502f5b5447de349216a40086ca6061efefb5a3025James Dong
2602f5b5447de349216a40086ca6061efefb5a3025James Dong// Redefine the int types
2702f5b5447de349216a40086ca6061efefb5a3025James Dongtypedef uint8_t uint8;
2802f5b5447de349216a40086ca6061efefb5a3025James Dongtypedef uint16_t uint16;
2902f5b5447de349216a40086ca6061efefb5a3025James Dongtypedef int16_t int16;
3002f5b5447de349216a40086ca6061efefb5a3025James Dongtypedef uint32_t uint32;
3102f5b5447de349216a40086ca6061efefb5a3025James Dongtypedef int32_t int32;
3202f5b5447de349216a40086ca6061efefb5a3025James Dongtypedef unsigned int uint;
3302f5b5447de349216a40086ca6061efefb5a3025James Dong
3402f5b5447de349216a40086ca6061efefb5a3025James Dong// Redefine the oscl memory management routines
3502f5b5447de349216a40086ca6061efefb5a3025James Dong#define oscl_memcpy memcpy
3602f5b5447de349216a40086ca6061efefb5a3025James Dong#define oscl_memset memset
3702f5b5447de349216a40086ca6061efefb5a3025James Dong#define oscl_malloc malloc
3802f5b5447de349216a40086ca6061efefb5a3025James Dong#define oscl_free free
3902f5b5447de349216a40086ca6061efefb5a3025James Dong#define oscl_memcmp memcmp
4002f5b5447de349216a40086ca6061efefb5a3025James Dong#define OSCL_DELETE(ptr) { delete(ptr); }
4102f5b5447de349216a40086ca6061efefb5a3025James Dong
4202f5b5447de349216a40086ca6061efefb5a3025James Dong// Request status values.  These are negative so that
4302f5b5447de349216a40086ca6061efefb5a3025James Dong// they won't conflict with system error codes.
4402f5b5447de349216a40086ca6061efefb5a3025James Dongconst int32 OSCL_REQUEST_ERR_NONE = 0;
4502f5b5447de349216a40086ca6061efefb5a3025James Dongconst int32 OSCL_REQUEST_PENDING = (-0x7fffffff);
4602f5b5447de349216a40086ca6061efefb5a3025James Dongconst int32 OSCL_REQUEST_ERR_CANCEL = (-1);
4702f5b5447de349216a40086ca6061efefb5a3025James Dongconst int32 OSCL_REQUEST_ERR_GENERAL = (-2);
4802f5b5447de349216a40086ca6061efefb5a3025James Dong
4902f5b5447de349216a40086ca6061efefb5a3025James Dong// Request status type
5002f5b5447de349216a40086ca6061efefb5a3025James Dongclass OsclAOStatus
5102f5b5447de349216a40086ca6061efefb5a3025James Dong{
5202f5b5447de349216a40086ca6061efefb5a3025James Dong    public:
5302f5b5447de349216a40086ca6061efefb5a3025James Dong        OsclAOStatus();
5402f5b5447de349216a40086ca6061efefb5a3025James Dong        OsclAOStatus(int32 aStatus);
5502f5b5447de349216a40086ca6061efefb5a3025James Dong        int32 operator=(int32 aStatus);
5602f5b5447de349216a40086ca6061efefb5a3025James Dong        int32 operator==(int32 aStatus) const;
5702f5b5447de349216a40086ca6061efefb5a3025James Dong        int32 operator!=(int32 aStatus) const;
5802f5b5447de349216a40086ca6061efefb5a3025James Dong        int32 operator>=(int32 aStatus) const;
5902f5b5447de349216a40086ca6061efefb5a3025James Dong        int32 operator<=(int32 aStatus) const;
6002f5b5447de349216a40086ca6061efefb5a3025James Dong        int32 operator>(int32 aStatus) const;
6102f5b5447de349216a40086ca6061efefb5a3025James Dong        int32 operator<(int32 aStatus) const;
6202f5b5447de349216a40086ca6061efefb5a3025James Dong        int32 Value() const;
6302f5b5447de349216a40086ca6061efefb5a3025James Dong    private:
6402f5b5447de349216a40086ca6061efefb5a3025James Dong        int32 iStatus;
6502f5b5447de349216a40086ca6061efefb5a3025James Dong};
6602f5b5447de349216a40086ca6061efefb5a3025James Dong
6702f5b5447de349216a40086ca6061efefb5a3025James Dong#endif  // M4V_H263_DECODER_PV_TYPES_H_
68