本文简单总结一下SDL显示视频的源代码。SDL显示视频的结构体SDL显示视频涉及到下列结构体:SDL_Window:代表了窗口SDL_Renderer:代表了渲染器SDL_Texture:代表了纹理SDL_Rect:一个矩形框,用于确定纹理显示的位置。上述几个结构体之间的关系如下图所示。注:该图源自于文章《最简单的基于FFmpeg+SDL的视频播放器2》 由图可见,YUV/RGB像素数据首先加载至...
分类:
其他好文 时间:
2014-11-18 01:39:49
阅读次数:
381
Red and Black
Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)
Total Submission(s): 10064 Accepted Submission(s): 6276
Problem Description
There is a rect...
分类:
其他好文 时间:
2014-11-15 15:35:20
阅读次数:
114
AcroExch.Rect 有四个属性:Top,Right,Left,Buttom1.单位:point,一般通过英寸换算,1point=1/72 inch(英寸)2.属性:Top: 区域距离 x 轴的距离,即Y轴值 ,而不是字面意思的顶部距离 (故当top=0,或 top <buttom 时,区域是...
分类:
其他好文 时间:
2014-11-13 12:37:51
阅读次数:
276
// Only override drawRect: if you perform custom drawing.
// An empty implementation adversely affects performance during animation.
- (void)drawRect:(CGRect)rect
{
CGContextRef contex...
分类:
移动开发 时间:
2014-11-13 09:24:05
阅读次数:
350
CCRect是cocos2dx中的一块矩形区域常用于碰撞检测及渲染时限定纹理的大小CCRect rect=spr.boundingBox();CCRect rect=CCRect(0,0,spr.width,spr.height);CCRect rect=CCRect(spr->boundingBo...
分类:
其他好文 时间:
2014-11-13 00:31:06
阅读次数:
200
HelloWorld! public class LinkInfo { public int line; public Rect bounds; public string token; public string p0; ...
分类:
其他好文 时间:
2014-11-12 19:33:18
阅读次数:
139
void Start(){ Rect screenRect = new Rect(0, 0, Screen.width, Screen.Height); } void Update{ Vector3 screenPos = targetCa...
分类:
其他好文 时间:
2014-11-11 12:34:35
阅读次数:
199
+ (UIImage*)createImageWithColor:(UIColor*)color{ CGRectrect=CGRectMake(0.0f,0.0f,1.0f,1.0f); UIGraphicsBeginImageContext(rect.size); CGContextRefcont...
分类:
其他好文 时间:
2014-11-10 19:53:45
阅读次数:
236
openCV作为已经成熟的开源库,很多操作它都已经有了高效,使用方便的方法。我的应用场景是这样的,从一张大图片中抠出一小部分,然后处理这一小部分后再放到大图像中。对于抠出来可以这样实现:Rect rect = Rect( x, y, width, height); Mat p = (Mat( src...
分类:
其他好文 时间:
2014-11-10 17:30:31
阅读次数:
173
Maximum Sum
Time Limit:500MS Memory Limit:65536KB 64bit IO Format:%I64d & %I64u
Submit Status
Description
Given a 2-dimensional array of positive and negative integers, find the sub-rect...
分类:
其他好文 时间:
2014-11-10 10:04:21
阅读次数:
119