openexr-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Openexr-devel] Writing a tiled Rgba image file with tiles given


From: Kevin Wheatley
Subject: Re: [Openexr-devel] Writing a tiled Rgba image file with tiles given
Date: Wed, 04 Mar 2009 09:46:02 +0000
User-agent: Thunderbird 2.0.0.18 (X11/20081119)

Florian Kainz wrote:
> memory location where pixel (0,0) would be if it existed.  If your
> buffer contains only a single tile, and that tile does not include
> pixel (0,0), then the base pointer just points outside the buffer.
> This may seem weird, but it works.  For a more detailed explanation

it is also relying on implementation defined/undefined behaviour in
the language standard - subtracting from the pointer results in a
location outside an allocated block of memory (give or take the one
past the end allowance) could result in all sorts of weird behaviour
depending on implementation by the compiler vendor.

I imagine on embedded systems your more likely to get problems or on
platforms where the address of the allocated memory block has a
smaller value vs the offset to base memory that the calculation
results in. This on some platforms could result in a calculation that
wraps to a very large memory address which could generare traps or
exceptions.

But this is a 'theory' rather than 'practice' statement on most
desktop platforms of course :-)

Kevin

-- 
| Kevin Wheatley, Cinesite (Europe) Ltd | Nobody thinks this      |
| Senior Technology                     | My employer for certain |
| And Network Systems Architect         | Not even myself         |
_________________________________________________________________________
Cinesite (Europe) Limited is a company registered in England and Wales
with company number 2820389.  VAT Registration: 630 5446 60
Registered Office: HemelOne, Boundary Way, Hemel Hempstead, Herts HP2 7YU




reply via email to

[Prev in Thread] Current Thread [Next in Thread]