Changeset 923 for branches/perian-1.1/Subtitles
- Timestamp:
- 08/02/08 16:24:20 (4 months ago)
- Files:
-
- branches/perian-1.1 (modified) (1 prop)
- branches/perian-1.1/Subtitles/SubATSUIRenderer.m (modified) (3 diffs)
- branches/perian-1.1/Subtitles/SubContext.h (modified) (1 diff)
- branches/perian-1.1/Subtitles/SubContext.m (modified) (1 diff)
- branches/perian-1.1/Subtitles/SubImport.mm (modified) (1 diff)
- branches/perian-1.1/Subtitles/SubUtilities.m (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
branches/perian-1.1
- Property svn:externals changed from
ffmpeg -r 13239 svn://svn.mplayerhq.hu/ffmpeg/trunk
libebml -r 1306 https://services.corecodec.com/svn/matroska/trunk/libebml
libmatroska -r 1306 https://services.corecodec.com/svn/matroska/trunk/libmatroska
a52codec -r 64 http://svn.cod3r.com/a52codec/trunk
to
ffmpeg -r 14508 svn://svn.mplayerhq.hu/ffmpeg/trunk
libebml -r 1306 https://services.corecodec.com/svn/matroska/trunk/libebml
libmatroska -r 1306 https://services.corecodec.com/svn/matroska/trunk/libmatroska
a52codec -r 64 http://svn.cod3r.com/a52codec/trunk
- Property svn:externals changed from
branches/perian-1.1/Subtitles/SubATSUIRenderer.m
r902 r923 350 350 -(void*)completedStyleParsing:(SubStyle*)s 351 351 { 352 const ATSUAttributeTag tags[] = {kATSUStyleRenderingOptionsTag, kATSUSizeTag, kATSUQDBoldfaceTag, kATSUQDItalicTag, kATSUQDUnderlineTag, kATSUStyleStrikeThroughTag, kATSUFontTag}; 353 const ByteCount sizes[] = {sizeof(ATSStyleRenderingOptions), sizeof(Fixed), sizeof(Boolean), sizeof(Boolean), sizeof(Boolean), sizeof(Boolean), sizeof(ATSUFontID)}; 354 355 ATSUFontID font = GetFontIDForSSAName(s->fontname); 352 const ATSUAttributeTag tags[] = {kATSUStyleRenderingOptionsTag, kATSUSizeTag, kATSUQDBoldfaceTag, kATSUQDItalicTag, kATSUQDUnderlineTag, kATSUStyleStrikeThroughTag, kATSUFontTag, kATSUVerticalCharacterTag}; 353 const ByteCount sizes[] = {sizeof(ATSStyleRenderingOptions), sizeof(Fixed), sizeof(Boolean), sizeof(Boolean), sizeof(Boolean), sizeof(Boolean), sizeof(ATSUFontID), sizeof(ATSUVerticalCharacterType)}; 354 355 NSString *fn = s->fontname; 356 ATSUVerticalCharacterType vertical = ParseFontVerticality(&fn) ? kATSUStronglyVertical : kATSUStronglyHorizontal; 357 ATSUFontID font = GetFontIDForSSAName(fn); 356 358 ATSFontRef fontRef = font; 357 359 ATSStyleRenderingOptions opt = kATSStyleApplyAntiAliasing; … … 360 362 ATSUStyle style; 361 363 362 const ATSUAttributeValuePtr vals[] = {&opt, &size, &b, &i, &u, &st, &font };364 const ATSUAttributeValuePtr vals[] = {&opt, &size, &b, &i, &u, &st, &font, &vertical}; 363 365 364 366 if (!s->platformSizeScale) s->platformSizeScale = GetWinFontSizeScale(fontRef); … … 462 464 sv(); 463 465 { 466 ATSUVerticalCharacterType vertical = ParseFontVerticality(&sval) ? kATSUStronglyVertical : kATSUStronglyHorizontal; 464 467 ATSUFontID font = GetFontIDForSSAName(sval); 465 468 466 if (font) SetATSUStyleOther(spanEx->style, kATSUFontTag, sizeof(ATSUFontID), &font); 469 if (font) { 470 SetATSUStyleFlag(spanEx->style, kATSUVerticalCharacterTag, vertical); 471 SetATSUStyleOther(spanEx->style, kATSUFontTag, sizeof(ATSUFontID), &font); 472 } 467 473 } 468 474 break; branches/perian-1.1/Subtitles/SubContext.h
r887 r923 55 55 56 56 extern UInt8 SSA2ASSAlignment(UInt8 a); 57 void ParseASSAlignment(UInt8 a, UInt8 *alignH, UInt8 *alignV);57 extern void ParseASSAlignment(UInt8 a, UInt8 *alignH, UInt8 *alignV); 58 58 extern SubRGBAColor ParseSSAColor(unsigned rgb); 59 extern BOOL ParseFontVerticality(NSString **fontname); branches/perian-1.1/Subtitles/SubContext.m
r893 r923 62 62 case 3: case 6: case 9: *alignH = kSubAlignmentRight; break; 63 63 } 64 } 65 66 BOOL ParseFontVerticality(NSString **fontname) 67 { 68 if ([*fontname characterAtIndex:0] == '@') { 69 *fontname = [*fontname substringFromIndex:1]; 70 return YES; 71 } 72 return NO; 64 73 } 65 74 branches/perian-1.1/Subtitles/SubImport.mm
r902 r923 1046 1046 { 1047 1047 priv = [[SubSerializer alloc] init]; 1048 CFRetain(priv); 1048 1049 } 1049 1050 1050 1051 CXXSubSerializer::~CXXSubSerializer() 1051 1052 { 1052 if (priv) { [(SubSerializer*)priv release]; priv = NULL;}1053 if (priv) {CFRelease(priv); [(SubSerializer*)priv release]; priv = NULL;} 1053 1054 } 1054 1055 branches/perian-1.1/Subtitles/SubUtilities.m
r887 r923 141 141 } 142 142 143 CFMutableStringRef GetHomeDirectory()143 CFMutableStringRef CopyHomeDirectory() 144 144 { 145 145 NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
