Home | History | Annotate | Download | only in inc
      1 /*
      2  * Copyright (c) 2010, Texas Instruments Incorporated
      3  * All rights reserved.
      4  *
      5  * Redistribution and use in source and binary forms, with or without
      6  * modification, are permitted provided that the following conditions
      7  * are met:
      8  *
      9  * *  Redistributions of source code must retain the above copyright
     10  *    notice, this list of conditions and the following disclaimer.
     11  *
     12  * *  Redistributions in binary form must reproduce the above copyright
     13  *    notice, this list of conditions and the following disclaimer in the
     14  *    documentation and/or other materials provided with the distribution.
     15  *
     16  * *  Neither the name of Texas Instruments Incorporated nor the names of
     17  *    its contributors may be used to endorse or promote products derived
     18  *    from this software without specific prior written permission.
     19  *
     20  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
     21  * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
     22  * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
     23  * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
     24  * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
     25  * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
     26  * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
     27  * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
     28  * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
     29  * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
     30  * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
     31  */
     32 
     33 /**
     34  *  @file  omx_rpc_stub.h
     35  *         This file contains methods that provides the functionality for
     36  *         the OpenMAX1.1 DOMX Framework RPC.
     37  *
     38  *  @path \WTSD_DucatiMMSW\framework\domx\omx_rpc\inc
     39  *
     40  *  @rev 1.0
     41  */
     42 
     43 /*==============================================================
     44  *! Revision History
     45  *! ============================
     46  *! 29-Mar-2010 Abhishek Ranka : Revamped DOMX implementation
     47  *!
     48  *! 19-August-2009 B Ravi Kiran ravi.kiran (at) ti.com: Initial Version
     49  *================================================================*/
     50 
     51 #ifndef OMX_RPC_STUBH
     52 #define OMX_RPC_STUBH
     53 
     54 #ifdef __cplusplus
     55 extern "C"
     56 {
     57 #endif				/* __cplusplus */
     58 
     59 /******************************************************************
     60  *   INCLUDE FILES
     61  ******************************************************************/
     62 #include "omx_rpc.h"
     63 #include "omx_rpc_internal.h"
     64 
     65 	RPC_OMX_ERRORTYPE RPC_GetHandle(OMX_HANDLETYPE hRPCCtx,
     66 	    OMX_STRING cComponentName, OMX_PTR pAppData,
     67 	    OMX_CALLBACKTYPE * pCallBacks, OMX_ERRORTYPE * nCmdStatus);
     68 
     69 	RPC_OMX_ERRORTYPE RPC_FreeHandle(OMX_HANDLETYPE hRPCCtx,
     70 	    OMX_ERRORTYPE * nCmdStatus);
     71 
     72 	RPC_OMX_ERRORTYPE RPC_UseBuffer(OMX_HANDLETYPE hRPCCtx,
     73 	    OMX_INOUT OMX_BUFFERHEADERTYPE ** ppBufferHdr, OMX_U32 nPortIndex,
     74 	    OMX_PTR pAppPrivate, OMX_U32 nSizeBytes, OMX_U8 * pBuffer,
     75 	    OMX_U32 * pBufHeaderRemote, OMX_ERRORTYPE * nCmdStatus);
     76 
     77 	RPC_OMX_ERRORTYPE RPC_SetParameter(OMX_HANDLETYPE hRPCCtx,
     78 	    OMX_INDEXTYPE nParamIndex, OMX_PTR pCompParam,
     79 	    OMX_PTR pLocBufNeedMap, OMX_ERRORTYPE * nCmdStatus);
     80 
     81 	RPC_OMX_ERRORTYPE RPC_GetParameter(OMX_HANDLETYPE hRPCCtx,
     82 	    OMX_INDEXTYPE nParamIndex, OMX_PTR pCompParam,
     83 	    OMX_PTR pLocBufNeedMap, OMX_ERRORTYPE * nCmdStatus);
     84 
     85 	RPC_OMX_ERRORTYPE RPC_FillThisBuffer(OMX_HANDLETYPE hRPCCtx,
     86 	    OMX_BUFFERHEADERTYPE * pBufferHdr, OMX_U32 BufHdrRemote,
     87 	    OMX_ERRORTYPE * nCmdStatus);
     88 
     89 	RPC_OMX_ERRORTYPE RPC_EmptyThisBuffer(OMX_HANDLETYPE hRPCCtx,
     90 	    OMX_BUFFERHEADERTYPE * pBufferHdr, OMX_U32 BufHdrRemote,
     91 	    OMX_ERRORTYPE * nCmdStatus,OMX_BOOL bMapBuffer);
     92 
     93 	RPC_OMX_ERRORTYPE RPC_FreeBuffer(OMX_HANDLETYPE hRPCCtx,
     94 	    OMX_IN OMX_U32 nPortIndex, OMX_IN OMX_U32 BufHdrRemote,
     95 	    OMX_U32 pBuffer, OMX_ERRORTYPE * nCmdStatus);
     96 
     97 	RPC_OMX_ERRORTYPE RPC_SetConfig(OMX_HANDLETYPE hRPCCtx,
     98 		OMX_INDEXTYPE nConfigIndex, OMX_PTR pCompConfig,
     99 		OMX_PTR pLocBufNeedMap, OMX_ERRORTYPE * nCmdStatus);
    100 
    101 	RPC_OMX_ERRORTYPE RPC_GetConfig(OMX_HANDLETYPE hRPCCtx,
    102 		OMX_INDEXTYPE nConfigIndex, OMX_PTR pCompConfig,
    103 		OMX_PTR pLocBufNeedMap, OMX_ERRORTYPE * nCmdStatus);
    104 
    105 	RPC_OMX_ERRORTYPE RPC_GetComponentVersion(OMX_HANDLETYPE hRPCCtx,
    106 	    OMX_STRING pComponentName, OMX_VERSIONTYPE * pComponentVersion,
    107 	    OMX_VERSIONTYPE * pSpecVersion, OMX_UUIDTYPE * pComponentUUID,
    108 	    OMX_ERRORTYPE * nCmdStatus);
    109 
    110 	RPC_OMX_ERRORTYPE RPC_SendCommand(OMX_HANDLETYPE hRPCCtx,
    111 	    OMX_COMMANDTYPE eCmd, OMX_U32 nParam, OMX_PTR pCmdData,
    112 	    OMX_ERRORTYPE * nCmdStatus);
    113 
    114 	RPC_OMX_ERRORTYPE RPC_GetState(OMX_HANDLETYPE hRPCCtx,
    115 	    OMX_STATETYPE * pState, OMX_ERRORTYPE * nCmdStatus);
    116 
    117 	RPC_OMX_ERRORTYPE RPC_GetExtensionIndex(OMX_HANDLETYPE hComponent,
    118 	    OMX_STRING cParameterName, OMX_INDEXTYPE * pIndexType,
    119 	    OMX_ERRORTYPE * nCmdStatus);
    120 
    121 	RPC_OMX_ERRORTYPE RPC_AllocateBuffer(OMX_HANDLETYPE hRPCCtx,
    122 	    OMX_INOUT OMX_BUFFERHEADERTYPE ** ppBufferHdr,
    123 	    OMX_IN OMX_U32 nPortIndex, OMX_U32 * pBufHeaderRemote,
    124 	    OMX_PTR pAppPrivate, OMX_U32 nSizeBytes,
    125 	    OMX_ERRORTYPE * nCmdStatus);
    126 
    127 	RPC_OMX_ERRORTYPE RPC_ComponentTunnelRequest(OMX_HANDLETYPE hRPCCtx,
    128 	    OMX_IN OMX_U32 nPort, OMX_HANDLETYPE hTunneledremoteHandle,
    129 	    OMX_U32 nTunneledPort,
    130 	    OMX_INOUT OMX_TUNNELSETUPTYPE * pTunnelSetup,
    131 	    OMX_ERRORTYPE * nCmdStatus);
    132 
    133 /*Empty Stubs*/
    134 	OMX_ERRORTYPE RPC_EventHandler(OMX_HANDLETYPE hRPCCtx,
    135 	    OMX_PTR pAppData, OMX_EVENTTYPE eEvent, OMX_U32 nData1,
    136 	    OMX_U32 nData2, OMX_PTR pEventData);
    137 	OMX_ERRORTYPE RPC_EmptyBufferDone(OMX_HANDLETYPE hRPCCtx,
    138 	    OMX_PTR pAppData, OMX_BUFFERHEADERTYPE * pBuffer);
    139 	OMX_ERRORTYPE RPC_FillBufferDone(OMX_HANDLETYPE hRPCCtx,
    140 	    OMX_PTR pAppData, OMX_BUFFERHEADERTYPE * pBuffer);
    141 
    142 #ifdef __cplusplus
    143 }
    144 #endif
    145 #endif
    146