1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1.2 +++ b/os/mm/mmdevicefw/mdf/src/openmax/omxoutputportbody.h Fri Jun 15 03:10:57 2012 +0200
1.3 @@ -0,0 +1,79 @@
1.4 +// Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
1.5 +// All rights reserved.
1.6 +// This component and the accompanying materials are made available
1.7 +// under the terms of "Eclipse Public License v1.0"
1.8 +// which accompanies this distribution, and is available
1.9 +// at the URL "http://www.eclipse.org/legal/epl-v10.html".
1.10 +//
1.11 +// Initial Contributors:
1.12 +// Nokia Corporation - initial contribution.
1.13 +//
1.14 +// Contributors:
1.15 +//
1.16 +// Description:
1.17 +//
1.18 +
1.19 +#ifndef OMXOUTPUTPORTBODY_H
1.20 +#define OMXOUTPUTPORTBODY_H
1.21 +
1.22 +#include <mdf/mdfoutputport.h>
1.23 +#include <mdf/mdfinputport.h>
1.24 +#include <omxprocessingunit.h>
1.25 +#include <omxoutputport.h>
1.26 +class TPuConfig;
1.27 +class CMMFBuffer;
1.28 +class COmxProcessingUnit;
1.29 +class MMDFInputPort;
1.30 +
1.31 +class COmxOutputPort::CBody : public CBase,
1.32 + public MOmxOutputPortCallbacks,
1.33 + public MMdfInputPortObserver
1.34 + {
1.35 +public:
1.36 + // from MMdfOutputPort
1.37 + static CBody* NewL(TInt aIndex, COmxProcessingUnit* aComponent, COmxOutputPort* aParent);
1.38 +
1.39 + TInt MopConfigure(const TPuConfig& aConfiguration);
1.40 + TInt MopGetConfig(TPuConfig& aConfigurationSetup);
1.41 + void MopInitialize();
1.42 + void MopSetObserver(const MMdfOutputPortObserver& aOutputPortObserver);
1.43 + CMMFBuffer* MopCreateBuffer(TInt aBufferSize);
1.44 + TInt MopUseBuffer(CMMFBuffer& aBuffer);
1.45 + TInt MopFreeBuffer(CMMFBuffer* aBuffer);
1.46 + TInt MopTunnelRequest(const MMdfInputPort& aInputPortToBeConnectedTo,
1.47 + TTunnelFlags& aTunnelFlags, TSupplierType& aSupplierType);
1.48 + void MopReadData(CMMFBuffer& aBuffer);
1.49 + void MopDisconnectTunnel();
1.50 + void MopRestartTunnel();
1.51 + TBool MopIsTunnelled() const;
1.52 + TInt MopIndex() const;
1.53 + TUint32 MopBufferSize() const;
1.54 + TInt MopCreateCustomInterface(TUid aUid);
1.55 + TAny* MopCustomInterface(TUid aUid);
1.56 +
1.57 + // from MOmxOutputPortCallbacks
1.58 + TInt FillBufferDone(OMX_HANDLETYPE hComponent, CMMFBuffer* pBuffer);
1.59 +
1.60 + // From MMdfInputPortObserver
1.61 + void MipoWriteDataComplete(const MMdfInputPort* aInputPort,
1.62 + CMMFBuffer* aBuffer, TInt aErrorCode);
1.63 + void MipoDisconnectTunnelComplete(const MMdfInputPort* aInputPort,
1.64 + TInt aErrorCode);
1.65 + void MipoRestartTunnelComplete(const MMdfInputPort* aInputPort,
1.66 + TInt aErrorCode);
1.67 +
1.68 + MMdfOutputPortObserver* Observer() const;
1.69 + COmxProcessingUnit* Component() const;
1.70 +
1.71 +private:
1.72 + CBody(TInt aIndex, COmxProcessingUnit* aComponent, COmxOutputPort* aParent);
1.73 +
1.74 + TInt iPortIndex;
1.75 + MMdfInputPort* iPortConnectedTo;
1.76 + COmxProcessingUnit* iComponent;
1.77 + MMdfOutputPortObserver* iObserver;
1.78 + TBool iStopped;
1.79 + COmxOutputPort* iParent;
1.80 + };
1.81 +
1.82 +#endif // OMXOUTPUTPORTBODY_H