• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (C) 2014 Amlogic Corporation.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *      http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
17 #ifndef _PLAYER_ERROR_H_
18 #define _PLAYER_ERROR_H_
19 
20 #define P_PRE       (0x02000000)
21 #define F_PRE       (0x03000000)
22 #define X_PRE       (0x04000000)
23 #define D_PRE       (0x05000000)
24 
25 #define PLAYER_SUCCESS          (0)
26 #define PLAYER_FAILED           (-(P_PRE|0x01))
27 #define PLAYER_NOMEM            (-(P_PRE|0x02))
28 #define PLAYER_EMPTY_P          (-(P_PRE|0x03))
29 #define PLAYER_NOT_VALID_PID    (-(P_PRE|0x04))
30 #define PLAYER_CAN_NOT_CREAT_THREADS    (-(P_PRE|0x05))
31 #define PLAYER_ERROR_PARAM      (-(P_PRE|0x06))
32 #define PLAYER_ERROR_CALLBACK   (-(P_PRE|0x07))
33 
34 #define PLAYER_RD_FAILED        (-(P_PRE|0x11))
35 #define PLAYER_RD_EMPTYP        (-(P_PRE|0x12))
36 #define PLAYER_RD_TIMEOUT       (-(P_PRE|0x13))
37 #define PLAYER_RD_AGAIN         (-(P_PRE|0x14))
38 
39 #define PLAYER_WR_FAILED        (-(P_PRE|0x21))
40 #define PLAYER_WR_EMPTYP        (-(P_PRE|0x22))
41 #define PLAYER_WR_AGAIN         (-(P_PRE|0x23))
42 #define PLAYER_WR_FINISH        (P_PRE|0x1)
43 
44 #define PLAYER_PTS_ERROR        (-(P_PRE|0x31))
45 #define PLAYER_NO_DECODER       (-(P_PRE|0x32))
46 #define DECODER_RESET_FAILED    (-(P_PRE|0x33))
47 #define DECODER_INIT_FAILED     (-(P_PRE|0x34))
48 #define PLAYER_UNSUPPORT        (-(P_PRE|0x35))
49 #define PLAYER_UNSUPPORT_VIDEO  (-(P_PRE|0x36))
50 #define PLAYER_UNSUPPORT_AUDIO  (-(P_PRE|0x37))
51 #define PLAYER_SEEK_OVERSPILL   (-(P_PRE|0x38))
52 #define PLAYER_CHECK_CODEC_ERROR  (-(P_PRE|0x39))
53 #define PLAYER_INVALID_CMD      (-(P_PRE|0x40))
54 #define PLAYER_REAL_AUDIO_FAILED (-(P_PRE|0x41))
55 #define PLAYER_ADTS_NOIDX       (-(P_PRE|0x42))
56 #define PLAYER_SEEK_FAILED      (-(P_PRE|0x43))
57 #define PLAYER_NO_VIDEO         (-(P_PRE|0x44))
58 #define PLAYER_NO_AUDIO         (-(P_PRE|0x45))
59 #define PLAYER_SET_NOVIDEO      (-(P_PRE|0x46))
60 #define PLAYER_SET_NOAUDIO      (-(P_PRE|0x47))
61 #define PLAYER_FFFB_UNSUPPORT   (-(P_PRE|0x48))
62 #define PLAYER_UNSUPPORT_VCODEC (-(P_PRE|0x49))
63 #define PLAYER_UNSUPPORT_ACODEC (-(P_PRE|0x4a))
64 
65 #define FFMPEG_SUCCESS          (0)
66 #define FFMPEG_OPEN_FAILED      (-(F_PRE|0x1))
67 #define FFMPEG_PARSE_FAILED     (-(F_PRE|0x2))
68 #define FFMPEG_EMP_POINTER      (-(F_PRE|0x3))
69 #define FFMPEG_NO_FILE          (-(F_PRE|0x4))
70 
71 #define DIVX_SUCCESS            (0)
72 #define DIVX_AUTHOR_ERR         (-(X_PRE|0x1))
73 #define DIVX_EXPIRED            (-(X_PRE|0x2))
74 
75 #define DRM_NOERROR             (0)
76 #define DRM_UNSUPPORT           (-(D_PRE|0x1))
77 
78 char * player_error_msg(int error);
79 #endif
80