⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 framedsource.h

📁 rtsp协议的主要实现代码.对开发流媒体
💻 H
字号:
// FramedSource.h: interface for the FramedSource class.
//
//////////////////////////////////////////////////////////////////////

#if !defined(AFX_FRAMEDSOURCE_H__8187FE74_331C_48A6_8F53_0CA579F1B304__INCLUDED_)
#define AFX_FRAMEDSOURCE_H__8187FE74_331C_48A6_8F53_0CA579F1B304__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
#include "winsock.h"

class FramedSource  
{
public:
	FramedSource();
	virtual ~FramedSource();

	typedef void (afterGettingFunc)(void* clientData, unsigned frameSize,
		unsigned numTruncatedBytes,
		struct timeval presentationTime,
		unsigned durationInMicroseconds);
	void getNextFrame(unsigned char* to, unsigned maxSize,afterGettingFunc* afterGettingFunc,
		void* afterGettingClientData);
	virtual void doGetNextFrame() = 0;
	// called by getNextFrame()

	virtual unsigned char GetPayloadFormatCode() = 0;
	void afterGetting(FramedSource* source);
protected:
	// The following variables are typically accessed/set by doGetNextFrame()
	unsigned char* fTo; // in
	unsigned fMaxSize; // in
	unsigned fFrameSize; // out
	unsigned fNumTruncatedBytes; // out
	struct timeval fPresentationTime; // out
	unsigned fDurationInMicroseconds; // out

	afterGettingFunc* fAfterGettingFunc;
	void* fAfterGettingClientData;
	Boolean fIsCurrentlyAwaitingData;
};

#endif // !defined(AFX_FRAMEDSOURCE_H__8187FE74_331C_48A6_8F53_0CA579F1B304__INCLUDED_)

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -