• 大小: 17.67MB
    文件类型: .zip
    金币: 1
    下载: 0 次
    发布日期: 2023-07-07
  • 语言: 其他
  • 标签: live555  

资源简介

liveMedia 项目(http://www.live555.com/)的源代码包括四个基本的库,各种测试代码以及Media Server。四个基本的库分别是: UsageEnvironment&TaskScheduler, groupsock, liveMedia和BasicUsageEnvironment。UsageEnvironment 和TaskScheduler 类用于事件的调度,实现异步读取事件的句柄的设置以及错误信息的输出。另外,还有一个HashTable 类定义了一个通用的hash 表,其它代码要用到这个表。这些都是抽象类,在应用程序中基于这些类来实现自己的子类。groups

资源截图

代码片段和文件信息

#include “H264framedLiveSource.hh“

H264framedLiveSource::H264framedLiveSource(UsageEnvironment& env int *datasize unsigned char*  databuf bool *dosent unsigned preferredframeSize unsigned playTimePerframe)
: framedSource(env)
{
framed_datasize = datasize;//数据区大小指针
framed_databuf = databuf;//数据区指针
framed_dosent = dosent;//发送标示
}

H264framedLiveSource* H264framedLiveSource::createNew(UsageEnvironment& env int *datasize unsigned char*  databuf bool *dosent unsigned preferredframeSize unsigned playTimePerframe)
{
H264framedLiveSource* newSource = new H264framedLiveSource(env datasize databuf dosent preferredframeSize playTimePerframe);
return newSource;
}

H264framedLiveSource::~H264framedLiveSource()
{
}

void H264framedLiveSource::doGetNextframe()
{
if (*framed_dosent == true)
{
*framed_dosent = false;
bufsizel = *framed_datasize;
readbufsize = 0;

fframeSize = fMaxSize;
memcpy(fTo framed_databuf + readbufsize fframeSize);
readbufsize += fframeSize;
}
else
{
if (bufsizel - readbufsize>fMaxSize)
{
fframeSize = fMaxSize;
memcpy(fTo framed_databuf + readbufsize fframeSize);
readbufsize += fframeSize;
}
else
{
memcpy(fTo framed_databuf + readbufsize bufsizel - readbufsize);
*framed_dosent = true;
}
}

nextTask() = envir().taskScheduler().scheduleDelayedTask(0(TaskFunc*)framedSource::afterGetting this);//表示延迟0秒后再执行 afterGetting 函数
return;
}

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----
     目录           0  2014-07-23 17:11  live555player\
     目录           0  2014-07-23 17:08  live555player\Debug\
     文件      779776  2014-07-23 17:09  live555player\Debug\live555player.exe
     文件     1804192  2014-07-23 17:09  live555player\Debug\live555player.ilk
     文件     2165760  2014-07-23 17:09  live555player\Debug\live555player.pdb
     文件     3032275  2010-01-29 16:42  live555player\Debug\test.264
     目录           0  2014-07-23 17:11  live555player\live555player\
     目录           0  2014-07-21 01:04  live555player\live555player\BasicUsageEnvironment\
     文件        7664  2014-05-15 00:03  live555player\live555player\BasicUsageEnvironment\BasicHashTable.cpp
     文件       10356  2014-05-20 09:38  live555player\live555player\BasicUsageEnvironment\BasicTaskScheduler.cpp
     文件        7512  2014-05-15 00:03  live555player\live555player\BasicUsageEnvironment\BasicTaskScheduler0.cpp
     文件        2437  2014-05-15 00:03  live555player\live555player\BasicUsageEnvironment\BasicUsageEnvironment.cpp
     文件        4316  2014-05-20 19:07  live555player\live555player\BasicUsageEnvironment\BasicUsageEnvironment.vcxproj
     文件        1557  2014-05-20 19:07  live555player\live555player\BasicUsageEnvironment\BasicUsageEnvironment.vcxproj.filters
     文件         165  2014-05-20 18:52  live555player\live555player\BasicUsageEnvironment\BasicUsageEnvironment.vcxproj.user
     文件        2622  2014-05-15 00:03  live555player\live555player\BasicUsageEnvironment\BasicUsageEnvironment0.cpp
     文件       24389  2014-05-15 00:04  live555player\live555player\BasicUsageEnvironment\COPYING
     目录           0  2014-07-21 01:04  live555player\live555player\BasicUsageEnvironment\Debug\
     文件       57946  2014-07-15 20:47  live555player\live555player\BasicUsageEnvironment\Debug\BasicHashTable.obj
     文件       57542  2014-07-15 20:47  live555player\live555player\BasicUsageEnvironment\Debug\BasicTaskScheduler.obj
     文件       69658  2014-07-15 20:47  live555player\live555player\BasicUsageEnvironment\Debug\BasicTaskScheduler0.obj
     目录           0  2014-07-21 01:04  live555player\live555player\BasicUsageEnvironment\Debug\BasicUsa.92E04722.tlog\
     文件         189  2014-07-15 20:47  live555player\live555player\BasicUsageEnvironment\Debug\BasicUsa.92E04722.tlog\BasicUsageEnvironment.lastbuildstate
     文件      252590  2014-07-15 20:47  live555player\live555player\BasicUsageEnvironment\Debug\BasicUsa.92E04722.tlog\CL.read.1.tlog
     文件       10022  2014-07-15 20:47  live555player\live555player\BasicUsageEnvironment\Debug\BasicUsa.92E04722.tlog\CL.write.1.tlog
     文件        5246  2014-07-15 20:47  live555player\live555player\BasicUsageEnvironment\Debug\BasicUsa.92E04722.tlog\Lib-link.read.1.tlog
     文件        2792  2014-07-15 20:47  live555player\live555player\BasicUsageEnvironment\Debug\BasicUsa.92E04722.tlog\Lib-link.write.1.tlog
     文件       10962  2014-07-15 20:47  live555player\live555player\BasicUsageEnvironment\Debug\BasicUsa.92E04722.tlog\cl.command.1.tlog
     文件        3512  2014-07-15 20:47  live555player\live555player\BasicUsageEnvironment\Debug\BasicUsa.92E04722.tlog\lib.command.1.tlog
     文件        2141  2014-07-15 20:47  live555player\live555player\BasicUsageEnvironment\Debug\BasicUsageEnvironment.log
     文件       47214  2014-07-15 20:47  live555player\live555player\BasicUsageEnvironment\Debug\BasicUsageEnvironment.obj
............此处省略634个文件信息

评论

共有 条评论