diff options
author | Thomas Dinges <blender@dingto.org> | 2014-05-11 05:38:39 +0400 |
---|---|---|
committer | Thomas Dinges <blender@dingto.org> | 2014-05-11 05:38:39 +0400 |
commit | c08c931fb6f57bdca7865d48ac09a0775590f3ce (patch) | |
tree | 8d5bbe8b0e23288d6227545811b3822eebf01fba /intern/cycles/render/image.cpp | |
parent | 8904eaf5047780eaf97eb7dc3acebb1b65f258bd (diff) |
Cycles / CUDA: Increase maximum image textures on GPU.
Instead of 95, we can use 145 images now. This only affects Kepler and above (sm30, sm_35 and sm_50).
This can be increased further if needed, but let's first test if this does not come with a performance impact.
Originally developed during my GSoC 2013.
Diffstat (limited to 'intern/cycles/render/image.cpp')
-rw-r--r-- | intern/cycles/render/image.cpp | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/intern/cycles/render/image.cpp b/intern/cycles/render/image.cpp index 8dde642f70b..86755badc42 100644 --- a/intern/cycles/render/image.cpp +++ b/intern/cycles/render/image.cpp @@ -59,11 +59,16 @@ void ImageManager::set_osl_texture_system(void *texture_system) osl_texture_system = texture_system; } -void ImageManager::set_extended_image_limits(void) +void ImageManager::set_extended_image_limits(const DeviceInfo& info) { - tex_num_images = TEX_EXTENDED_NUM_IMAGES; - tex_num_float_images = TEX_EXTENDED_NUM_FLOAT_IMAGES; - tex_image_byte_start = TEX_EXTENDED_IMAGE_BYTE_START; + if(info.type == DEVICE_CPU) { + tex_num_images = TEX_EXTENDED_NUM_IMAGES_CPU; + tex_num_float_images = TEX_EXTENDED_NUM_FLOAT_IMAGES; + tex_image_byte_start = TEX_EXTENDED_IMAGE_BYTE_START; + } + else if((info.type == DEVICE_CUDA || info.type == DEVICE_MULTI) && info.extended_images) { + tex_num_images = TEX_EXTENDED_NUM_IMAGES_GPU; + } } bool ImageManager::set_animation_frame_update(int frame) |