diff options
-rw-r--r-- | intern/cycles/render/image.cpp | 3 | ||||
-rw-r--r-- | intern/cycles/render/image.h | 7 |
2 files changed, 10 insertions, 0 deletions
diff --git a/intern/cycles/render/image.cpp b/intern/cycles/render/image.cpp index 7bceb8a8bfa..7a846e1dd46 100644 --- a/intern/cycles/render/image.cpp +++ b/intern/cycles/render/image.cpp @@ -69,6 +69,9 @@ void ImageManager::set_extended_image_limits(const DeviceInfo& info) else if((info.type == DEVICE_CUDA || info.type == DEVICE_MULTI) && info.extended_images) { tex_num_images = TEX_EXTENDED_NUM_IMAGES_GPU; } + else if(info.pack_images) { + tex_num_images = TEX_PACKED_NUM_IMAGES; + } } bool ImageManager::set_animation_frame_update(int frame) diff --git a/intern/cycles/render/image.h b/intern/cycles/render/image.h index bcc58ae951b..c79c152afde 100644 --- a/intern/cycles/render/image.h +++ b/intern/cycles/render/image.h @@ -40,6 +40,13 @@ CCL_NAMESPACE_BEGIN #define TEX_EXTENDED_NUM_IMAGES_CPU 1024 #define TEX_EXTENDED_IMAGE_BYTE_START TEX_EXTENDED_NUM_FLOAT_IMAGES +/* Limitations for packed images. + * + * Technically number of textures is unlimited, but it should in + * fact be in sync with CPU limitations. + */ +#define TEX_PACKED_NUM_IMAGES 1024 + /* color to use when textures are not found */ #define TEX_IMAGE_MISSING_R 1 #define TEX_IMAGE_MISSING_G 0 |