Main Page   Class Hierarchy   Data Structures   File List   Data Fields   Globals  

pv_2way_basic_types.h

Go to the documentation of this file.
00001 /*
00002 * ==============================================================================
00003 *  Name        : pv_2way_basic_types
00004 *  Part of     :
00005 *  Interface   :
00006 *  Description : Basic / low-level enums and types used by PV2Way engine
00007 *  Version     : (see RELEASE field in copyright header above)
00008 *
00009 * ==============================================================================
00010 */
00011 
00012 #ifndef PV_2WAY_BASIC_TYPES_H_INCLUDED
00013 #define PV_2WAY_BASIC_TYPES_H_INCLUDED
00014 
00015 #ifndef PVMF_FORMAT_TYPE_H_INCLUDED
00016 #include "pvmf_format_type.h"
00017 #endif
00018 
00019 #ifndef OSCL_VECTOR_H_INCLUDED
00020 #include "oscl_vector.h"
00021 #endif
00022 
00023 #ifndef OSCL_MEM_H_INCLUDED
00024 #include "oscl_mem.h"
00025 #endif
00026 
00027 
00028 // CONSTANTS
00030 const int PV2WayErrorStatusStart = (-10500);
00032 const int PV2WayDispatchError = PV2WayErrorStatusStart - 1;
00034 const int PV2WayDisconnectError = PV2WayErrorStatusStart - 2;
00036 const int PV2WayErrorRejected = PV2WayErrorStatusStart - 5;
00038 const int PV2WayErrReplaced = PV2WayErrorStatusStart - 6;
00039 
00040 // DATA TYPES
00045 typedef enum TPVTerminalType
00046 {
00047     PV_323,/* based on H.323 */
00048     PV_324M, /* based on H.324m */
00049     PV_SIP, /* based on SIP */
00050     PV_TERMINAL_TYPE_NONE
00051 } PV2WayTerminalType;
00052 
00058 typedef enum TPVLoopbackMode
00059 {
00060     PV_LOOPBACK_NONE,
00061     PV_LOOPBACK_COMM, /* Loops back from Comm source to Comm sink */
00062     PV_LOOPBACK_ENGINE, /* Loops back media at the engine level, no mux involved */
00063     PV_LOOPBACK_MUX /* Loops back at the output of the mux */
00064 } PV2WayLoopbackMode;
00065 
00071 typedef enum TPVDirection
00072 {
00073     PV_DIRECTION_NONE = 0,
00074     INCOMING = 1,
00075     OUTGOING = 2,
00076     PV_DIRECTION_BOTH = 3
00077 } PV2WayDirection;
00078 
00082 typedef enum TPVMediaType_t
00083 {
00084     PV_MEDIA_NONE = 0,
00085     PV_CONTROL = 1,
00086     PV_AUDIO = 2,
00087     PV_VIDEO = 4,
00088     PV_DATA = 8,
00089     PV_USER_INPUT = 16,
00090     PV_MULTIPLEXED = 32,
00091     PV_MEDIA_ALL = 0xFFFF
00092 } PV2WayMediaType;
00093 
00099 typedef unsigned int PVTrackId;
00100 
00106 typedef enum
00107 {
00112     EIdle = 0,
00119     EInitializing,
00127     ESetup,
00132     EConnecting,
00136     EConnected,
00140     EDisconnecting,
00144     EResetting
00145 } PV2WayState;
00146 
00153 enum TPVTIndicationType
00154 {
00155 
00164     PVT_INDICATION_INCOMING_TRACK,
00173     PVT_INDICATION_OUTGOING_TRACK,
00179     PVT_INDICATION_DISCONNECT,
00186     PVT_INDICATION_CLOSING_TRACK,
00195     PVT_INDICATION_CLOSE_TRACK,
00203     PVT_INDICATION_PAUSE_TRACK,
00210     PVT_INDICATION_RESUME_TRACK,
00216     PVT_INDICATION_INTERNAL_ERROR,
00217 };
00218 
00219 
00220 // CLASS DECLARATION
00221 
00230 class PV2WayInitInfo
00231 {
00232     public:
00237         virtual void GetInitInfoClassName(OSCL_wString& aClassName) = 0;
00238 
00239         virtual ~PV2WayInitInfo() { }
00240 
00244         Oscl_Vector<PVMFFormatType, OsclMemAllocator> iOutgoingAudioFormats;
00245 
00249         Oscl_Vector<PVMFFormatType, OsclMemAllocator> iOutgoingVideoFormats;
00250 
00254         Oscl_Vector<PVMFFormatType, OsclMemAllocator> iIncomingAudioFormats;
00255 
00259         Oscl_Vector<PVMFFormatType, OsclMemAllocator> iIncomingVideoFormats;
00260 
00261 };
00262 
00263 
00269 class PV2WayConnectOptions
00270 {
00271     public:
00275         PV2WayConnectOptions()
00276                 : iLoopbackMode(PV_LOOPBACK_NONE),
00277                 iLocalId(NULL),
00278                 iLocalIdSize(0),
00279                 iRemoteId(NULL),
00280                 iRemoteIdSize(0) {}
00281 
00293         PV2WayConnectOptions(TPVLoopbackMode aLoopbackMode,
00294                              uint8* aLocalId, uint32 aLocalIdSize,
00295                              uint8* aRemoteId, uint32 aRemoteIdSize)
00296                 : iLoopbackMode(aLoopbackMode),
00297                 iLocalId(aLocalId),
00298                 iLocalIdSize(aLocalIdSize),
00299                 iRemoteId(aRemoteId),
00300                 iRemoteIdSize(aRemoteIdSize)
00301         {}
00302 
00303         virtual ~PV2WayConnectOptions() {};
00304 
00313         virtual void GetConnectInfoClassName(OSCL_wString &aClassName) = 0;
00314 
00318         TPVLoopbackMode iLoopbackMode;
00319 
00323         uint8* iLocalId;
00327         uint32 iLocalIdSize;
00328 
00332         uint8* iRemoteId;
00336         uint32 iRemoteIdSize;
00337 };
00338 #endif

PV2Way Engine
Posting Version: CORE_8.508.1.1