Cycles: Cleanup after recent refactor
Wrong indentation, wrong spacing.
This commit is contained in:
@@ -233,13 +233,11 @@ int ImageManager::type_index_to_flattened_slot(int slot, ImageDataType type)
|
|||||||
|
|
||||||
int ImageManager::flattened_slot_to_type_index(int flat_slot, ImageDataType *type)
|
int ImageManager::flattened_slot_to_type_index(int flat_slot, ImageDataType *type)
|
||||||
{
|
{
|
||||||
if(flat_slot >= tex_image_byte_start)
|
if(flat_slot >= tex_image_byte_start) {
|
||||||
{
|
|
||||||
*type = IMAGE_DATA_TYPE_BYTE;
|
*type = IMAGE_DATA_TYPE_BYTE;
|
||||||
return flat_slot - tex_image_byte_start;
|
return flat_slot - tex_image_byte_start;
|
||||||
}
|
}
|
||||||
else if(flat_slot >= tex_image_float_start)
|
else if(flat_slot >= tex_image_float_start) {
|
||||||
{
|
|
||||||
*type = IMAGE_DATA_TYPE_FLOAT;
|
*type = IMAGE_DATA_TYPE_FLOAT;
|
||||||
return flat_slot - tex_image_float_start;
|
return flat_slot - tex_image_float_start;
|
||||||
}
|
}
|
||||||
@@ -817,7 +815,7 @@ void ImageManager::device_load_image(Device *device, DeviceScene *dscene, ImageD
|
|||||||
img->extension);
|
img->extension);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if(type == IMAGE_DATA_TYPE_BYTE4){
|
else if(type == IMAGE_DATA_TYPE_BYTE4) {
|
||||||
device_vector<uchar4>& tex_img = dscene->tex_byte4_image[slot];
|
device_vector<uchar4>& tex_img = dscene->tex_byte4_image[slot];
|
||||||
|
|
||||||
if(tex_img.device_pointer) {
|
if(tex_img.device_pointer) {
|
||||||
@@ -901,7 +899,7 @@ void ImageManager::device_free_image(Device *device, DeviceScene *dscene, ImageD
|
|||||||
|
|
||||||
tex_img.clear();
|
tex_img.clear();
|
||||||
}
|
}
|
||||||
else if(type == IMAGE_DATA_TYPE_BYTE4){
|
else if(type == IMAGE_DATA_TYPE_BYTE4) {
|
||||||
device_vector<uchar4>& tex_img = dscene->tex_byte4_image[slot];
|
device_vector<uchar4>& tex_img = dscene->tex_byte4_image[slot];
|
||||||
|
|
||||||
if(tex_img.device_pointer) {
|
if(tex_img.device_pointer) {
|
||||||
|
Reference in New Issue
Block a user