本文整理汇总了C++中VideoFrame::setNoInterlaced方法的典型用法代码示例。如果您正苦于以下问题:C++ VideoFrame::setNoInterlaced方法的具体用法?C++ VideoFrame::setNoInterlaced怎么用?C++ VideoFrame::setNoInterlaced使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类VideoFrame
的用法示例。
在下文中一共展示了VideoFrame::setNoInterlaced方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: filter
void DiscardDeint::filter(QQueue< FrameBuffer > &framesQueue)
{
int insertAt = addFramesToDeinterlace(framesQueue);
while (!internalQueue.isEmpty())
{
FrameBuffer dequeued = internalQueue.dequeue();
VideoFrame *videoFrame = VideoFrame::fromData(dequeued.data);
const bool TFF = isTopFieldFirst(videoFrame);
videoFrame->setNoInterlaced();
for (int p = 0; p < 3; ++p)
{
const int linesize = videoFrame->linesize[p];
quint8 *src = videoFrame->data[p];
quint8 *dst = videoFrame->data[p];
const int lines = (p ? h >> 2 : h >> 1) - 1;
if (!TFF)
{
memcpy(dst, src + linesize, linesize);
src += linesize;
dst += linesize;
}
dst += linesize;
src += linesize;
for (int i = 0; i < lines; ++i)
{
VideoFilters::averageTwoLines(dst, src - linesize, src + linesize, linesize);
src += linesize << 1;
dst += linesize << 1;
}
if (TFF)
memcpy(dst, src - linesize, linesize);
}
framesQueue.insert(insertAt++, dequeued);
}
}
示例2: filter
void BlendDeint::filter(QQueue< FrameBuffer > &framesQueue)
{
int insertAt = addFramesToDeinterlace(framesQueue);
while (!internalQueue.isEmpty())
{
FrameBuffer dequeued = internalQueue.dequeue();
VideoFrame *videoFrame = VideoFrame::fromData(dequeued.data);
videoFrame->setNoInterlaced();
for (int p = 0; p < 3; ++p)
{
const int linesize = videoFrame->linesize[p];
quint8 *src = videoFrame->data[p] + linesize;
quint8 *dst = videoFrame->data[p] + linesize;
const int H = (p ? h >> 1 : h >> 0) - 2;
for (int i = 0; i < H; ++i)
{
VideoFilters::averageTwoLines(dst, src, src + linesize, linesize);
src += linesize;
dst += linesize;
}
}
framesQueue.insert(insertAt++, dequeued);
}
}