From: John F. <jo...@us...> - 2010-08-27 17:41:40
|
Update of /cvsroot/ingex/ingex/common/YUVlib In directory sfp-cvsdas-4.v30.ch3.sourceforge.com:/tmp/cvs-serv21335/common/YUVlib Modified Files: YUV_text_overlay.c Log Message: NTSC timecode support Index: YUV_text_overlay.c =================================================================== RCS file: /cvsroot/ingex/ingex/common/YUVlib/YUV_text_overlay.c,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** YUV_text_overlay.c 2 Jun 2010 10:52:38 -0000 1.5 --- YUV_text_overlay.c 27 Aug 2010 17:41:32 -0000 1.6 *************** *** 915,919 **** int c; ! for (c = 0; c < 11; c++) free_overlay(&tc_data->tc_ovly[c]); } --- 915,919 ---- int c; ! for (c = 0; c < 12; c++) free_overlay(&tc_data->tc_ovly[c]); } *************** *** 925,929 **** info_rec* info; FT_GlyphSlot slot; ! char cset[] = "0123456789:"; int bb_t, bb_b, bb_l, bb_r; // bounding box BYTE* dstLine; --- 925,929 ---- info_rec* info; FT_GlyphSlot slot; ! char cset[] = "0123456789:;"; int bb_t, bb_b, bb_l, bb_r; // bounding box BYTE* dstLine; *************** *** 950,954 **** bb_l = 1000000; bb_r = -1000000; ! for (c = 0; c < 11; c++) { /* load glyph image into the slot (erase previous one) */ --- 950,954 ---- bb_l = 1000000; bb_r = -1000000; ! for (c = 0; c < 12; c++) { /* load glyph image into the slot (erase previous one) */ *************** *** 972,976 **** tc_data->height = bb_b - bb_t; // initialise character overlays ! for (c = 0; c < 11; c++) { tc_data->tc_ovly[c].w = bb_r - bb_l; --- 972,976 ---- tc_data->height = bb_b - bb_t; // initialise character overlays ! for (c = 0; c < 12; c++) { tc_data->tc_ovly[c].w = bb_r - bb_l; *************** *** 987,991 **** } // copy bitmaps ! for (c = 0; c < 11; c++) { /* load glyph image into the slot (erase previous one) */ --- 987,991 ---- } // copy bitmaps ! for (c = 0; c < 12; c++) { /* load glyph image into the slot (erase previous one) */ *************** *** 993,999 **** return YUV_freetype; slot = info->face->glyph; /* a small shortcut */ ! if (c == 10) { ! // make colon narrower than other characters tc_data->tc_ovly[c].w = slot->advance.x / 64; } --- 993,999 ---- return YUV_freetype; slot = info->face->glyph; /* a small shortcut */ ! if (c == 10 || c == 11) { ! // make colon and semi-colon narrower than other characters tc_data->tc_ovly[c].w = slot->advance.x / 64; } *************** *** 1013,1017 **** } tc_data->width = (tc_data->tc_ovly[0].w * 8) + ! (tc_data->tc_ovly[10].w * 3); // 8 digits and 3 colons return YUV_OK; } --- 1013,1017 ---- } tc_data->width = (tc_data->tc_ovly[0].w * 8) + ! (tc_data->tc_ovly[11].w * 3); // 8 digits and 3 semi-colons (assuming a semi-colon is wider than a colon) return YUV_OK; } |