rtc.avd_SDK-C++  3.2.0
Public 成员函数 | 静态 Public 成员函数 | Protected 成员函数 | 所有成员列表
rtc::IVideoRender类 参考abstract

视频渲染接口类 更多...

类 rtc::IVideoRender 继承关系图:
rtc::DestroyNotify

Public 成员函数

virtual void SetSize (int width, int height)=0
 视频宽高变化调用 更多...
 
virtual void RenderFrame (const IVideoFrame &frame)=0
 视频帧数据到达调用 更多...
 
virtual Result EnableCapture (bool enable)
 启停图像抓取功能 更多...
 
virtual Result CaptureImage (const String &fileName, int quality)
 抓取图像 更多...
 
virtual Result GetWindowId (AvdWindowId &id) const
 获取render所在的WindowId 更多...
 
virtual Result GetSize (int &width, int &height) const
 获取图像大小 更多...
 
virtual Result SetAnnotation (rtc::IMAnnotation *atn)
 设置注释接口 更多...
 
virtual Result GetAnnotation (rtc::IMAnnotation **atn)
 获取注释接口 更多...
 
virtual Result setFirstFrameListener (IFirstFrameListener *listener)
 设置首帧数据回调指针 更多...
 
virtual int32 SetRemoteCtrlModule (IRemoteCtrl *remote, std::string othersideuid)
 设置远程控制模块,对方userid 更多...
 
virtual Result FillBlack ()
 
virtual bool getIsGdiView ()
 获取该render是否用gdi模式创建的 更多...
 
- Public 成员函数 继承自 rtc::DestroyNotify
virtual Result AddDestroyNotify (IListener *pListener)
 设置渲染对象销毁回调指针 更多...
 
virtual Result RemoveDestroyNotify (IListener *pListener)
 删除渲染对象销毁回调指针 更多...
 
virtual ~DestroyNotify ()
 
void Clear ()
 

静态 Public 成员函数

static Result Save2Image (const IVideoFrame *frame, const String &jpegorbmpFileName, int quality)
 IVideoFrame图像保存为jpeg图像功能 更多...
 

Protected 成员函数

virtual ~IVideoRender ()
 

额外继承的成员函数

- Public 类型 继承自 rtc::DestroyNotify
typedef std::vector< IListener * > ListenersType
 
- Protected 属性 继承自 rtc::DestroyNotify
ListenersType pListeners_
 

详细描述

视频渲染接口类

视频渲染定义了视频的渲染中涉及的视频参数变化、视频帧数据、视频抓图等相关接口。

构造及析构函数说明

◆ ~IVideoRender()

virtual rtc::IVideoRender::~IVideoRender ( )
protectedvirtual

成员函数说明

◆ CaptureImage()

virtual Result rtc::IVideoRender::CaptureImage ( const String &  fileName,
int  quality 
)
virtual

抓取图像

参数
[in]fileName图像保存地址,绝对地址, 支持".bmp和.jpg"。
[in]quality图像质量:0-100, 0最差,100最好。
返回
返回错误代码。

引用了 Err_Not_Implemented.

◆ EnableCapture()

virtual Result rtc::IVideoRender::EnableCapture ( bool  enable)
virtual

启停图像抓取功能

参数
[in]enable开启或者停止。
返回
返回错误代码。
注解
渲染的时候,正常情况下不缓存图像; 若需要capture才做缓存;因EnableCapture后,要下帧图像放到缓存中才能做Save2Image。 故若需要capture时,在attachRender后就直接EnableCapture较好。

引用了 Err_Not_Implemented.

◆ FillBlack()

virtual Result rtc::IVideoRender::FillBlack ( )
virtual

引用了 Err_Not_Implemented.

◆ GetAnnotation()

virtual Result rtc::IVideoRender::GetAnnotation ( rtc::IMAnnotation **  atn)
virtual

获取注释接口

参数
[out]atn注释模块接口。
返回
返回错误代码。

引用了 Err_Not_Implemented.

◆ getIsGdiView()

virtual bool rtc::IVideoRender::getIsGdiView ( )
virtual

获取该render是否用gdi模式创建的

◆ GetSize()

virtual Result rtc::IVideoRender::GetSize ( int &  width,
int &  height 
) const
virtual

获取图像大小

参数
[out]width图像宽度。
[out]height图像高度。
返回
返回错误代码。

引用了 Err_Not_Implemented.

◆ GetWindowId()

virtual Result rtc::IVideoRender::GetWindowId ( AvdWindowId &  id) const
virtual

获取render所在的WindowId

参数
[in,out]id显示对象句柄。
返回
返回错误代码。

引用了 Err_Not_Implemented.

◆ RenderFrame()

virtual void rtc::IVideoRender::RenderFrame ( const IVideoFrame &  frame)
pure virtual

视频帧数据到达调用

参数
[in]frameIVideoFrame图像对象指针。

◆ Save2Image()

static Result rtc::IVideoRender::Save2Image ( const IVideoFrame *  frame,
const String &  jpegorbmpFileName,
int  quality 
)
static

IVideoFrame图像保存为jpeg图像功能

参数
[in]frameIVideoFrame图像对象指针。
[in]jpegorbmpFileName图像保存地址,绝对地址, 支持".bmp和.jpg"。
[in]quality图像质量:0-100, 0最差,100最好。
返回
返回错误代码。

◆ SetAnnotation()

virtual Result rtc::IVideoRender::SetAnnotation ( rtc::IMAnnotation *  atn)
virtual

设置注释接口

参数
[out]atn注释模块接口。
返回
返回错误代码。

引用了 Err_Not_Implemented.

◆ setFirstFrameListener()

virtual Result rtc::IVideoRender::setFirstFrameListener ( IFirstFrameListener *  listener)
virtual

设置首帧数据回调指针

参数
[in]listener首帧数据回调指针。
返回
返回错误代码。
注解
此函数设置后,VideoRender在首帧视频数据接收到时会回调onFirstFrameArrived; 注意:每次重新attachRender后需要重新设置此函数,即设置此函数后,只有一次回调,下次即使同一VideoRender需要再次获取首帧回调,需要重新设置。

引用了 Err_Not_Implemented.

◆ SetRemoteCtrlModule()

virtual int32 rtc::IVideoRender::SetRemoteCtrlModule ( IRemoteCtrl *  remote,
std::string  othersideuid 
)
virtual

设置远程控制模块,对方userid

引用了 Err_Not_Implemented.

◆ SetSize()

virtual void rtc::IVideoRender::SetSize ( int  width,
int  height 
)
pure virtual

视频宽高变化调用

参数
[in]width视频宽度。
[in]height视频高度。

该类的文档由以下文件生成: