471,873 Members | 1,683 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,873 software developers and data experts.

Working with unsigned/signed types

Hi everyone-
I've been away from coding for a while (I turned into a professional
photographer)...
So now I've taken up a project involving working with EXIF and XMP metadatain
image files (mainly JPEG and TIFF), and am having some trouble figuring outhow
to handle some of the data...

Here's what I'm having to do:
Inside the files, there are various types of data which can be split apart and
organized fairly easily, given you have unsigned and signed types... Whichis
where I'm running into problems remembering how everything works.

The first part of the question is fairly basic - in C, working with signed
integers, the MSB (is that still the right term?) is used to denote positive and
negative, and the following bits increase towards positive infinity, correct?
Such that in C, adding one to 0x7fffffff would cause the number to go around to
-0x7fffffff (or whatever that is), giving -1 for 0xffffffff?

Secondly, (and this is my weak point as a programmer) to re-insert the data
after, what would be the most efficient way to pull everything back apart into
individual characters for putting it all back into the files? I could probably
figure out something that would work, but I wouldn't be so sure as to its
reliability.

Third, being a photographer now rather than a coder, I'd like to give back the
modules I'm writing to the community (it looks like very little of the sort
exists), but would rather not worry about them in the future... Is there agood
way to go about this?

Thanks!
-Brian Shirk

Avalanche Photography LLC
www.AvalanchePhoto.com
McCall, Idaho
Dec 20 '06 #1
0 786

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

9 posts views Thread by dam_fool_2003 | last post: by
22 posts views Thread by juanitofoo | last post: by
10 posts views Thread by =?iso-8859-2?B?SmFuIFJpbmdvuQ==?= | last post: by
26 posts views Thread by John Harrison | last post: by
6 posts views Thread by Kislay | last post: by
reply views Thread by YellowAndGreen | last post: by
reply views Thread by zermasroor | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.