RTPMPComponentVideo_Initialize(
	RTPMPComponentVideoInstanceData **	inGlobals,
	SInt32								inFlags )
{
	ComponentResult		theResult;
	
	
	if( CallComponentCanDo( ( **inGlobals ).itsBase, kRTPMPInitializeSelect ) )
		theResult = RTPMPInitialize( ( **inGlobals ).itsBase, inFlags );
	else
		theResult = noErr;
	
	if( theResult == noErr )
	{
		( **inGlobals ).itsPacketBuilder = NULL;
		( **inGlobals ).itsPacketSizeLimit = __kDefaultPacketSizeLimit;
		( **inGlobals ).itsPacketDurationLimit = __kDefaultPacketDurationLimit;
		
		ComponentVideoPayloadInitialize( &( **inGlobals ).itsPayloadHeader, 0, 0 );
		
		( **inGlobals ).itsInitialized = true;
	}
	
	return( theResult );
}
PASCAL_RTN ComponentResult ADD_BASENAME(CanDo)( COMPONENT_GLOBALS(), short ftnNumber )
{
	ComponentResult	result;
#if C_DISPATCH_WITH_GLOBALS
	ProcInfoType ignore;
	result = (ComponentResult) COMPONENTSELECTORLOOKUP(ftnNumber, &ignore);
#else
	result = (ComponentResult) COMPONENTSELECTORLOOKUP(ftnNumber);
#endif
	
	/* check for a ComponentError */
	if ( result == (ComponentResult) kCOMPONENT_ERROR )
		result = false;
	else if ( result == (ComponentResult) kCOMPONENT_DELEGATE )
		result = false;
	else
		result = true;

#ifdef GET_DELEGATE_COMPONENT
	/* if we're delegated, then keep looking */
	if (!result)
		{
		if (GET_DELEGATE_COMPONENT())
			result = CallComponentCanDo( GET_DELEGATE_COMPONENT(), ftnNumber );
		}
#endif

#ifdef OVERRIDE_CANDO
	result = OVERRIDE_CANDO( storage, ftnNumber, result);
#else
	TOUCH_UNUSED_ARG(storage);
#endif

	return result;
}
RTPMPComponentVideo_Reset(
	RTPMPComponentVideoInstanceData **	inGlobals,
	SInt32								inFlags )
{
	ComponentResult		theResult;
	
	
	ComponentVideoPayloadInitialize( &( **inGlobals ).itsPayloadHeader, 0, 0 );
	
	if( CallComponentCanDo( ( **inGlobals ).itsBase, kRTPMPResetSelect ) )
		theResult = RTPMPReset( ( **inGlobals ).itsBase, inFlags );
	else
		theResult = noErr;
	
	return( theResult );
}
RTPMPComponentVideo_Flush(
	RTPMPComponentVideoInstanceData **	inGlobals,
	SInt32				inFlags,
	SInt32 *			outFlags )
{
	ComponentResult		theResult;
	
	
	if( CallComponentCanDo( ( **inGlobals ).itsBase, kRTPMPFlushSelect ) )
	{
		theResult = RTPMPFlush( ( **inGlobals ).itsBase, inFlags, outFlags );
	}
	
	else
	{
		theResult = noErr;
		*outFlags = 0;
	}
	
	return( theResult );
}