[X264_CSP_YUYV] = { 1, { 256*2 }, { 256*1 }, }, [X264_CSP_UYVY] = { 1, { 256*2 }, { 256*1 }, }, [X264_CSP_I444] = { 3, { 256*1, 256*1, 256*1 }, { 256*1, 256*1, 256*1 } }, [X264_CSP_YV24] = { 3, { 256*1, 256*1, 256*1 }, { 256*...
#defineX264_CSP_YUYV0x0009/* yuyv 4:2:2 packed */#defineX264_CSP_UYVY0x000a/* uyvy 4:2:2 packed */#defineX264_CSP_V2100x000b/* 10-bit yuv 4:2:2 packed in 32 */#defineX264_CSP_I4440x000c/* yuv 4:4:4 planar */#defineX264_CSP_YV240x000d/* yvu 4:4:4 planar...
2 planar */ #define X264_CSP_NV16 0x0008 /* yuv 4:2:2, with one y plane and one packed u+v */ #define X264_CSP_YUYV 0x0009 /* yuyv 4:2:2 packed */ #define X264_CSP_UYVY 0x000a /* uyvy 4:2:2 packed */ #define X264_CSP_V210 0x000b /* 10-bit yuv 4:2:2 ...
第一个我想要讲的就是param->i_csp,csp是color space的缩写,中文意思是颜色空间,或者彩色空间;描述的是颜色集合的数学表示,颜色空间的表达方式称之为颜色格式,常见的有YUV以及RGB;其实在物理世界里面是有多种现象需要经过信息化的处理,将自然界或者物理世界存在的现象用信息化(也即二进制的方式表达出来),比如常见...
(14)x264_csp_init这是不同颜色空间转换相关的一些函数。结构体x264_csp_function_t中是相关的转换函数指针。 pf->i420 = i420_to_i420; pf->i422 = i422_to_i420; pf->i444 = i444_to_i420; pf->yv12 = yv12_to_i420; pf->yuyv = yuyv_to_i420; pf->rgb = rgb_to_i420; pf->bgr =...
#define X264_CSP_I422 0x0006 /* yuv 4:2:2 planar */ #define X264_CSP_YV16 0x0007 /* yvu 4:2:2 planar */ #define X264_CSP_NV16 0x0008 /* yuv 4:2:2, with one y plane and one packed u+v */ #define X264_CSP_YUYV 0x0009 /* yuyv 4:2:2 packed */ ...
FILE*fp_dst = fopen(argv[2],"wb");//Encode 0 frameintframe_num =50;intcsp = X264_CSP_I422;//YUYVintwidth=640,height=480;//640*480intiNal =0; x264_nal_t*pNals =NULL; x264_t*pHandle =NULL; x264_picture_t*pPic_in = (x264_picture_t *)malloc(sizeof(x264_picture_t));...
/*设置视频录制相关参数*/static int x264_param_apply_preset(x264_param_t *param, const char *preset){char *end;int i = strtol( preset, &end, 10 );if( *end == 0 && i >= 0 && i < sizeof(x264_preset_names)/sizeof(*x264_preset_names)-1 )preset = x264_preset_names[i];...
(requires lavf support) --input-csp <string> Specify input colorspace format for raw input - valid csps for `raw' demuxer: i400, i420, yv12, nv12, nv21, i422, yv16, nv16, yuyv, uyvy, i444, yv24, bgr, bgra, rgb - valid csps for `lavf' demuxer: yuv420p, yuyv422, rgb24,...
i_csp = X264_CSP_I420; en->picture->img.i_plane = 3; } /*结束压缩*/ void compress_end(Encoder *en) { if (en->picture) { x264_picture_clean(en->picture); free(en->picture); en->picture = 0; } if(en->param) { free(en->param); en->param = 0; } if(en->handle) ...