EXIF格式分析及通过XML处理(4)[3]

[入库:2006年2月23日] [更新:2007年3月24日]

本文简介:

        pChild->Text = Format( "0x%X", ARRAYOFCONST( ( ( int )ent.EntrySize ) ) );

        pChild = pEntry->AddChild( "Value" );

        switch ( ent.EntryType ) {

        case 1 :  // BYTE

            if ( ent.EntrySize == 1 )

                pChild->Text = Format( "0x%.02X", ARRAYOFCONST( ( ( int )( BYTE )ent.EntryValue ) ) );

            else

                throw Exception( "Unsupported!" );

            break;

        case 2 :  // ASCII

            if ( ent.EntrySize <= 4 )

                pChild->Text = reinterpret_cast<LPSTR>( &ent.EntryValue );

            else

                pChild->Text = reinterpret_cast<LPSTR>( aTIFFHeader + ent.EntryValue );

            break;

        case 3 :  // SHORT

            if ( ent.EntrySize == 1 )

                pChild->Text = Format( "0x%.04X", ARRAYOFCONST( ( ( int )( WORD )ent.EntryValue ) ) );

            else

                throw Exception( "Unsupported!" );

本文关键:EXIF XML XSL
 

本站最佳浏览方式为 分辨率 1024x768 IE 6.0(或更高版本的 IE浏览器)

go top