OpenMAX Bellagio 0.9.3
OMX_ContentPipe.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2008 The Khronos Group Inc.
3 *
4 * Permission is hereby granted, free of charge, to any person obtaining
5 * a copy of this software and associated documentation files (the
6 * "Software"), to deal in the Software without restriction, including
7 * without limitation the rights to use, copy, modify, merge, publish,
8 * distribute, sublicense, and/or sell copies of the Software, and to
9 * permit persons to whom the Software is furnished to do so, subject
10 * to the following conditions:
11 * The above copyright notice and this permission notice shall be included
12 * in all copies or substantial portions of the Software.
13 *
14 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
15 * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
16 * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
17 * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
18 * CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
19 * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
20 * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
21 *
22 */
23
29
30#ifndef OMX_CONTENTPIPE_H
31#define OMX_CONTENTPIPE_H
32
33#ifndef KD_EACCES
34/* OpenKODE error codes. CPResult values may be zero (indicating success
35 or one of the following values) */
36#define KD_EACCES (1)
37#define KD_EADDRINUSE (2)
38#define KD_EAGAIN (5)
39#define KD_EBADF (7)
40#define KD_EBUSY (8)
41#define KD_ECONNREFUSED (9)
42#define KD_ECONNRESET (10)
43#define KD_EDEADLK (11)
44#define KD_EDESTADDRREQ (12)
45#define KD_ERANGE (35)
46#define KD_EEXIST (13)
47#define KD_EFBIG (14)
48#define KD_EHOSTUNREACH (15)
49#define KD_EINVAL (17)
50#define KD_EIO (18)
51#define KD_EISCONN (20)
52#define KD_EISDIR (21)
53#define KD_EMFILE (22)
54#define KD_ENAMETOOLONG (23)
55#define KD_ENOENT (24)
56#define KD_ENOMEM (25)
57#define KD_ENOSPC (26)
58#define KD_ENOSYS (27)
59#define KD_ENOTCONN (28)
60#define KD_EPERM (33)
61#define KD_ETIMEDOUT (36)
62#define KD_EILSEQ (19)
63#endif
64
67typedef char * CPstring;
68typedef void * CPhandle;
70typedef OMX_S32 CPint;
71typedef char CPbyte;
73
85
97
119
131
135typedef struct CP_PIPETYPE
136{
138 CPresult (*Open)( CPhandle* hContent, CPstring szURI, CP_ACCESSTYPE eAccess );
139
141 CPresult (*Close)( CPhandle hContent );
142
144 CPresult (*Create)( CPhandle *hContent, CPstring szURI );
145
147 CPresult (*CheckAvailableBytes)( CPhandle hContent, CPuint nBytesRequested, CP_CHECKBYTESRESULTTYPE *eResult );
148
150 CPresult (*SetPosition)( CPhandle hContent, CPint nOffset, CP_ORIGINTYPE eOrigin);
151
153 CPresult (*GetPosition)( CPhandle hContent, CPuint *pPosition);
154
157 CPresult (*Read)( CPhandle hContent, CPbyte *pData, CPuint nSize);
158
171 CPresult (*ReadBuffer)( CPhandle hContent, CPbyte **ppBuffer, CPuint *nSize, CPbool bForbidCopy);
172
175
178 CPresult (*Write)( CPhandle hContent, CPbyte *data, CPuint nSize);
179
183 CPresult (*GetWriteBuffer)( CPhandle hContent, CPbyte **ppBuffer, CPuint nSize);
184
187 CPresult (*WriteBuffer)( CPhandle hContent, CPbyte *pBuffer, CPuint nFilledSize);
188
190 CPresult (*RegisterCallback)( CPhandle hContent, CPresult (*ClientCallback)(CP_EVENTTYPE eEvent, CPuint iParam));
191
193
194#endif
195
OMX_U32 CPuint
OMX_S32 CPint
void * CPhandle
char * CPstring
char CPbyte
OMX_U32 CPresult
OMX_BOOL CPbool
unsigned long OMX_U32
Definition OMX_Types.h:145
OMX_BOOL
Definition OMX_Types.h:189
signed long OMX_S32
Definition OMX_Types.h:148
CP_ACCESSTYPE
CP_EVENTTYPE
CP_ORIGINTYPE
CP_CHECKBYTESRESULTTYPE
@ CP_AccessWrite
@ CP_AccessReadWrite
@ CP_AccessKhronosExtensions
@ CP_AccessRead
@ CP_AccessVendorStartUnused
@ CP_AccessMax
@ CP_Overflow
@ CP_EventKhronosExtensions
@ CP_EventVendorStartUnused
@ CP_EventMax
@ CP_PipeDisconnected
@ CP_BytesAvailable
@ CP_OriginCur
@ CP_OriginKhronosExtensions
@ CP_OriginVendorStartUnused
@ CP_OriginBegin
@ CP_OriginEnd
@ CP_OriginMax
@ CP_CheckBytesVendorStartUnused
@ CP_CheckBytesNotReady
@ CP_CheckBytesAtEndOfStream
@ CP_CheckBytesInsufficientBytes
@ CP_CheckBytesKhronosExtensions
@ CP_CheckBytesOutOfBuffers
@ CP_CheckBytesOk
@ CP_CheckBytesMax
CPresult(* ReleaseReadBuffer)(CPhandle hContent, CPbyte *pBuffer)
CPresult(* Create)(CPhandle *hContent, CPstring szURI)
CPresult(* WriteBuffer)(CPhandle hContent, CPbyte *pBuffer, CPuint nFilledSize)
CPresult(* Write)(CPhandle hContent, CPbyte *data, CPuint nSize)
CPresult(* RegisterCallback)(CPhandle hContent, CPresult(*ClientCallback)(CP_EVENTTYPE eEvent, CPuint iParam))
CPresult(* CheckAvailableBytes)(CPhandle hContent, CPuint nBytesRequested, CP_CHECKBYTESRESULTTYPE *eResult)
CPresult(* ReadBuffer)(CPhandle hContent, CPbyte **ppBuffer, CPuint *nSize, CPbool bForbidCopy)
CPresult(* SetPosition)(CPhandle hContent, CPint nOffset, CP_ORIGINTYPE eOrigin)
CPresult(* Open)(CPhandle *hContent, CPstring szURI, CP_ACCESSTYPE eAccess)
CPresult(* GetPosition)(CPhandle hContent, CPuint *pPosition)
CPresult(* GetWriteBuffer)(CPhandle hContent, CPbyte **ppBuffer, CPuint nSize)
CPresult(* Close)(CPhandle hContent)
CPresult(* Read)(CPhandle hContent, CPbyte *pData, CPuint nSize)

Generated for OpenMAX Bellagio rel. 0.9.3 by  doxygen 1.5.1
SourceForge.net Logo