Maximum image size which is possible to render ?

Started by patrick, October 16, 2008, 09:27:57 PM

Previous topic - Next topic

patrick

 :) I try to render an image bigger than 10 000 by 8000 pixels , but if i go higher than this size the program crash .
Is it possible to go higher , if yes, how ?
I have plenty of memory so i can't be problem .

Thanks for an answer

Patrick Mimran

Oshyan

There is no absolute limit, but memory is definitely a concern. It is not only dependent on how much total memory you have, since TG2 is a 32 bit application, and even under ideal circumstances can only ever have a maximum of 4GB of memory to itself. See this thread for some more info:

http://forums.planetside.co.uk/index.php?topic=4916.0

- Oshyan

cyphyr

Just out of interest would it be possible to run two or more instances of TG2 side by side and have them use concurrent sections of ram so the first instance of TG2 would use ram from 0 to 4gb and the second instance would use ram to 4bg to 8gb or thereabouts (massage the numbers to make it real ish). If I run my 32 bit app in a 64 bit environment is the 32 bit app restricted by its operating environment or by its core programming?
richard
www.richardfraservfx.com
https://www.facebook.com/RichardFraserVFX/
/|\

Ryzen 9 5950X OC@4Ghz, 64Gb (TG4 benchmark 4:13)

jo

Hi Richard,

It doesn't really work like that. The OS may choose to partition memory more or less along those lines, but there are no guarantees it will. The application has no idea where in RAM the memory is coming from, the OS sets up an environment for the application to run in and the app think it's working in that environment.

Regards,

Jo

patrick

I do not know , but have have plenty of memory so even with 10000 7000 pixel the final file won't be more than 1 gig so why it crashes right away with more than 10000 7000 render size .
I get very unclear  answers , is it possible Yes or Not ?

Thanks for your help

Patrick Mimran :)


Matt

#5
The memory needed to render a 10000x7000 image is probably higher than you think. Terragen renders using image buffers which have 4 bytes per colour channel per pixel. It also renders a 3-channel alpha image in addition to the 3-channel RGB image. Those 6 colour channels require 24 bytes per pixel. For a 10000x7000 pixel image Terragen needs *at least* 1602 Mb (10000 * 7000 * 6 = 1 680 000 000 bytes, which is about 1602 Mb). It would attempt to allocate those in 2 blocks of 801 Mb (801Mb for the RGB image plus 801Mb for the alpha image), and that is quite a large block of memory to ask the OS to allocate in a contiguous chunk. Not only that, other image buffers are needed by Terragen to render individual buckets (tiles), and these use up another hundred Mb or sometimes more. Before any of that can be allocated, the rest of Terragen and your scene file may be using a significant amount of memory already. During rendering, more memory will be needed for other things, most importantly the ray tracer subdiv cache (whose size you can control in the render settings) and cloud acceleration caches.

(EDITED) Because TG2 is currently a 32-bit application, the maximum amount of address space it can access is 4Gb on a 64-bit OS, approximately 3Gb on a 32-bit Mac or 32-bit Windows with the /3GB switch enabled, and only 2Gb on a standard 32-bit Windows setup. Even if you have more than 4Gb of RAM installed on your computer, these limits apply. They are only theoretical maxima, and in practice the OS may not be able to give Terragen all of that memory. (/EDITED)

With all that in mind, 10000 x 7000 is probably very close to the maximum resolution that TG2 is currently capable of on a 32-bit system. On 64-bit systems you can probably go a fair bit larger, but I doubt that you could go much larger than 15000 x 10000. If your scene has imported objects in it, or populations, it will be using more memory before rendering even begins, so the maximum resolution will be lower. Other rendering processes need memory after rendering has started and these may cause rendering errors if there is not enough left after allocating memory for the image.

So the simple answer is that we don't know exactly what the maximum image size is, and it depends on your computer, the scene you're trying to render, and your render settings.

After 2.0 has been released we are going to work on a 64-bit build for TG2, allowing it to go beyond the 4Gb barrier on 64-bit systems. We may also look at improved memory handling for large images, using tiling and other techniques to avoid allocating such large chunks of memory, which will be better for everybody.

Matt
Just because milk is white doesn't mean that clouds are made of milk.

Matt

#6
There are a few things you can do to improve the chances of successfully rendering larger images, in addition to closing any other running programs:

- Restart the computer before rendering very large images or complex renders.
- Close the 3D Preview as soon as Terragen starts.
- Save memory by reducing the size of the subdiv cache, found in the Advanced tab of the render settings. Unfortunately, very large, detailed renders usually benefit from a larger subdiv cache, not smaller, so it should only be reduced if you really need to save memory. I would not recommend going below 100 Mb if the image is large.
- Set "maximum threads" to 0 or 1 (on the Advanced tab of the render settings). On multi-processor or multi-core computers this will prevent more than 1 thread from being used for rendering, so Terragen does not need to duplicate any rendering systems which can't be shared between threads. This will save some memory, and allow your subdiv cache to go further.

Matt
Just because milk is white doesn't mean that clouds are made of milk.

Matt

I saw from your other thread that you have a 64-bit Mac with 32Mb of RAM. So in theory I would expect that 10000 x 8000 should be possible. Take a look at the suggestions I made in the above post to make sure you give Terragen as much available memory as possible.

Matt
Just because milk is white doesn't mean that clouds are made of milk.