|
简单的jpeg转成avi的类(4) DWORD imp_colors; // important colors /* may be more for some codeCS */ AVI_strf () {} AVI_strf (DWORD s, DWORD w, DWORD h, DWORD p, char const* c, DWORD i, DWORD x, DWORD y, DWORD n, DWORD imp) :sz (s), width (w), height (h), planes_bit_cnt (p), image_sz (i) ,xpels_meter (x), ypels_meter (y), num_colors (n), imp_colors (imp) { for (int i = 0; i < 4; ++i) compression[i] = c[i]; } AVI_strf (AVI_strf const& strf) { sz = strf.sz; width = strf.width; height = strf.height; planes_bit_cnt = strf.planes_bit_cnt; image_sz = strf.image_sz; xpels_meter = strf.xpels_meter; ypels_meter = strf.ypels_meter; num_colors = strf.num_colors; imp_colors = strf.imp_colors; for (int i = 0; i < 4; ++i) compression[i] = strf.compression[i]; } ~AVI_strf () {} friend ostream& operator << (ostream& out, AVI_strf const& strf) { out << strf.sz << out << strf.width << strf.height << strf.planes_bit_cnt; out << strf.compression[0] << strf.compression[1] << strf.compression[2] << strf.compression[3]; out << strf.image_sz << strf.xpels_meter << strf.ypels_meter << strf.num_colors << strf.imp_colors; return out; } }; /* AVI_list_hdr spc: a very ubiquitous AVI struct, used in list structures to specify type and length */ struct AVI_list_hdr { unsigned char id[4]; /* "LIST" */
|