Document: HDRI-MemUse.pdf Link: https://www.horo.ch/docs/mine/pdf/HDRI-MemUse.pdf HDRI Memory Usage The memory needed to load and tone-map an HDRI in Bryce is investi-gated and how much additional memory is needed to export it. Preamble Bryce does everything in memory and the question arises how big an HDRI can be to be loaded into Bryce. What happens if the loaded HDRI is tone-mapped and exported? HDRI that Load The file must be in the Radiance RGBE format, file extension .hdr; the data compressed using the version 2 RLE scheme as most HDRI capable programs create. Bryce cannot read uncom-pressed radiance files or those using the RLE method version 1. The image files can either be in square aspect ratio (1:1) or half as high then wide (2:1). An image with an aspect ratio of 1:1 is assumed to be in the Angular Map projection; if it is in aspect ratio 2:1, the Spherical projection is assumed. If an image is in another projection, it will be displayed wrongly; if in another aspect ratio it will not load. Tone-mapping A loaded HDRI can be tone-mapped. The tone-mapping process needs a lot of memory, twice or more of what the HDRI uses, but once the process is concluded, the extra memory is freed. The tone-mapped image stays in memory. HDRI Export Any HDRI loaded can be exported in different LDRI and HDRI file formats and different projections. Not all work, some crash Bryce outright and some are incomplete and crash Bryce anyway. [Picture] The example above used a spherical HDRI with the size of 1024 x 512 pixels and the result of exporting it to a tone-mapped spherical panorama. Bryce crashed after having saved 53%. <<<< Page 2 >>>> The resulting image is 1268 x 634 pixels. Memory is not an issue with such a small HDRI to export. Tone-mapping - if enabled - and conversion work fine, Bryce crashes when saving the file, but not immediately, about half way to 2/3 through the process and this can be observed up to HDRI sizes of 12,800 x 6,400 pixels and beyond. Export Options The table shows that exporting from a spherical HDRI does not work for spherical output, neither for a cylindrical QTVR while from an Angular Map HDRI all options work. The HTML export blocks the Sky Lab and control can be resumed by hitting the [ESC]-key. No file results, but then, it is not clear what this option was intended to produce anyway. The document HDRI Export http://www.horo.ch/docs/mine/pdf/HDRIexport.pdf shows that an HDRI exported from a Bryce Sky starts with the Angular Map. [Table] Size of exported image The size of the exported image cannot be set by the user, Bryce determines the size auto-matically. An Angular Map as loaded HDRI is assumed. a) Export as Angular Map: copy of loaded HDRI or a copy of the tone-mapped variant. b) Export as spherical: diameter of HDRI multiplied by 1.24 gives the width and the height is half of that. c) Export as a horizontal or vertical cross is a bit more complicated. A cross consists of 6 tiles and the tile size is: square of half the diameter of the HDRI multiplied by PI multiplied by 4; the result divided by 6 and from this the square root is taken and this result divided by 2. For the horizontal cross, this tile size is multiplied by 4 to get the width and by 3 to get the height. The vertical cross has just the width and the height reversed. Note that the size of the exported image may be slightly different. Bryce recalculates the size of the loaded HDRI so that there are no fractions in the divisions. The diameter is equal to one side of the square aspect ratio HDRI. If an HDRI in the spherical projection is loaded, the results differ. d) Export as Angular Map: diameter is half the width of the HDRI (i.e. its height). e)Export as cross, the tile size is derived from the Angular Map, which is half the width (or the height) of the HDRI (see d) and from there continue with (c). <<<< Page 3 >>>> f) Export as spherical: incomplete, width is 1.24 times the original width and Bryce crashes. Brightness The brightness for the resulting image - whether tone-mapped or not - must be set before exporting using the Intensity control. Check how the image looks by rendering the HDRI as backdrop and adjust Intensity until satisfied. The HDRI will be exported in this brightness as LDRI or HDRI depending on which type is selected. If the HDRI is not tone-mapped and exported as LDRI, it is nevertheless tone-mapped but using a linear operator, not the photographic one. The linear (default) tone-mapping operator gives a high contrast LDRI suited to be mapped on a sphere to supply specular and reflection for a scene using no HDRI; and space scenes. The photographic operator is based on Erik Reinhard's work and gives a natural looking representation. Shadows are brightened and strong lights (like the sun) softened. Memory usage It is not known how the HDRI is stored in memory; therefore a table of measurements is pre-sented. For each probe diameter, Bryce was started anew. Memory usage was determined with Process Monitor for Bryce only - the Task Manager is not adequate for the task. Idle means the memory used for the default scene just after launching Bryce. [Table] The most memory (and time) intensive is tone-mapping. Memory usage drops when done but more is used then before. This is because the tone-mapped image is kept in memory and once an HDRI has been tone-mapped, it can be toggled on and off without delay. Obviously, tone-mapping uses the most of the memory. To check how big an HDRI can be and still be tone-mapped, Bryce was set to Large Address Aware (amber rows). [Table] Unfortunately, spherical HDRIs cannot be exported in the spherical projection because this crashes Bryce. Except for the 16,160 x 8,080 HDRI, all saved about 2/3 of the exported image before the crash occurred. The last created a BMP of 20,038 x 10,019 pixels with a few vertical lines before Bryce run out of memory. October 2014/horo