[Nottingham] Tweaking the orientation flag in a jpeg
roger at atchoo.org
Wed Sep 1 13:03:19 UTC 2010
I don't, but it's fairly simple to put together. I've created a quick
C program that should do what you want. It's at
It's pretty basic - it assumes that the files will fit into memory
completely for example.
You'll need to modify it first to set the offset of the byte that you
want to change. Then compile it with "gcc -o tweak tweak.c"
After that, run either as:
./tweak <input file>
which will overwrite the input file (no guarantees you won't lose your
./tweak <input file> <output file>
On Wed, Sep 1, 2010 at 12:44 PM, Graham Dicker
<graham.dicker at antecor.com> wrote:
> Hi everyone
> Does anyone know of a utility that can modify just one byte at a given offset
> in a file? I want to change the orientation flag in a set of jpegs for which
> lossless rotate is not an option. The flag is at the same offset in every file
> and just needs to be changed from a 1 to a 6.
> Nottingham mailing list
> Nottingham at mailman.lug.org.uk
More information about the Nottingham