Subversion Repositories filter_foundry

Rev

Rev 378 | Rev 488 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 378 Rev 465
Line 116... Line 116...
116
 
116
 
117
function ostype_info($type, $desc, $vendor) {
117
function ostype_info($type, $desc, $vendor) {
118
        $dec = 0;
118
        $dec = 0;
119
        for ($i=0;$i<4;$i++) $dec = ($dec<<8) + ord($type[$i]);
119
        for ($i=0;$i<4;$i++) $dec = ($dec<<8) + ord($type[$i]);
120
        $hex = "0x".str_pad(dechex($dec), 8, "0", STR_PAD_LEFT);
120
        $hex = "0x".str_pad(dechex($dec), 8, "0", STR_PAD_LEFT);
121
        $dec = str_pad($dec, strlen(hexdec('ffffffff')), " ", STR_PAD_LEFT);
121
        $dec = str_pad((string)$dec, strlen((string)hexdec('ffffffff')), " ", STR_PAD_LEFT);
122
        $desc = str_pad($desc, DESC_WIDTH, " ", STR_PAD_RIGHT);
122
        $desc = str_pad($desc, DESC_WIDTH, " ", STR_PAD_RIGHT);
123
 
123
 
124
        $illegal = false;
124
        $illegal = false;
125
        if ($vendor != '?') {
125
        if ($vendor != '?') {
126
                $is_all_uppercase = strtoupper($type) == $type;
126
                $is_all_uppercase = strtoupper($type) == $type;
Line 157... Line 157...
157
 
157
 
158
function pipl_property_info($ven, $type, $desc, $vendor) {
158
function pipl_property_info($ven, $type, $desc, $vendor) {
159
        $vdec = 0;
159
        $vdec = 0;
160
        for ($i=0;$i<4;$i++) $vdec = ($vdec<<8) + ord($ven[$i]);
160
        for ($i=0;$i<4;$i++) $vdec = ($vdec<<8) + ord($ven[$i]);
161
        $vhex = "0x".str_pad(dechex($vdec), 8, "0", STR_PAD_LEFT);
161
        $vhex = "0x".str_pad(dechex($vdec), 8, "0", STR_PAD_LEFT);
162
        $vdec = str_pad($vdec, strlen(hexdec('ffffffff')), " ", STR_PAD_LEFT);
162
        $vdec = str_pad((string)$vdec, strlen((string)hexdec('ffffffff')), " ", STR_PAD_LEFT);
163
 
163
 
164
        $dec = 0;
164
        $dec = 0;
165
        for ($i=0;$i<4;$i++) $dec = ($dec<<8) + ord($type[$i]);
165
        for ($i=0;$i<4;$i++) $dec = ($dec<<8) + ord($type[$i]);
166
        $hex = "0x".str_pad(dechex($dec), 8, "0", STR_PAD_LEFT);
166
        $hex = "0x".str_pad(dechex($dec), 8, "0", STR_PAD_LEFT);
167
        $dec = str_pad($dec, strlen(hexdec('ffffffff')), " ", STR_PAD_LEFT);
167
        $dec = str_pad((string)$dec, strlen((string)hexdec('ffffffff')), " ", STR_PAD_LEFT);
168
 
168
 
169
        $desc = str_pad($desc, DESC_WIDTH, " ", STR_PAD_RIGHT);
169
        $desc = str_pad($desc, DESC_WIDTH, " ", STR_PAD_RIGHT);
170
 
170
 
171
        // In re 8B##, we just assume that 8B## was legally assigned to Adobe by Apple
171
        // In re 8B##, we just assume that 8B## was legally assigned to Adobe by Apple
172
        // Note: "8B" sounds like "Adobe"
172
        // Note: "8B" sounds like "Adobe"