[Bf-blender-cvs] [b416168] master: Cycles: Cleanup, trailing whitespace
Sergey Sharybin
noreply at git.blender.org
Tue Aug 2 14:09:39 CEST 2016
Commit: b416168d85a7cf5a27370f5c933fd1ad41ee333d
Author: Sergey Sharybin
Date: Tue Aug 2 11:28:20 2016 +0200
Branches: master
https://developer.blender.org/rBb416168d85a7cf5a27370f5c933fd1ad41ee333d
Cycles: Cleanup, trailing whitespace
===================================================================
M intern/cycles/device/device_cuda.cpp
===================================================================
diff --git a/intern/cycles/device/device_cuda.cpp b/intern/cycles/device/device_cuda.cpp
index 0b3c31a..6a511ea 100644
--- a/intern/cycles/device/device_cuda.cpp
+++ b/intern/cycles/device/device_cuda.cpp
@@ -1004,11 +1004,11 @@ public:
if(!background) {
PixelMem pmem = pixel_mem_map[mem];
CUdeviceptr buffer;
-
+
size_t bytes;
cuda_assert(cuGraphicsMapResources(1, &pmem.cuPBOresource, 0));
cuda_assert(cuGraphicsResourceGetMappedPointer(&buffer, &bytes, pmem.cuPBOresource));
-
+
return buffer;
}
@@ -1040,9 +1040,9 @@ public:
glBufferData(GL_PIXEL_UNPACK_BUFFER, pmem.w*pmem.h*sizeof(GLhalf)*4, NULL, GL_DYNAMIC_DRAW);
else
glBufferData(GL_PIXEL_UNPACK_BUFFER, pmem.w*pmem.h*sizeof(uint8_t)*4, NULL, GL_DYNAMIC_DRAW);
-
+
glBindBuffer(GL_PIXEL_UNPACK_BUFFER, 0);
-
+
glGenTextures(1, &pmem.cuTexId);
glBindTexture(GL_TEXTURE_2D, pmem.cuTexId);
if(mem.data_type == TYPE_HALF)
@@ -1052,7 +1052,7 @@ public:
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST);
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST);
glBindTexture(GL_TEXTURE_2D, 0);
-
+
CUresult result = cuGraphicsGLRegisterBuffer(&pmem.cuPBOresource, pmem.cuPBO, CU_GRAPHICS_MAP_RESOURCE_FLAGS_NONE);
if(result == CUDA_SUCCESS) {
@@ -1154,9 +1154,9 @@ public:
else
glTexSubImage2D(GL_TEXTURE_2D, 0, 0, 0, w, h, GL_RGBA, GL_UNSIGNED_BYTE, (void*)offset);
glBindBuffer(GL_PIXEL_UNPACK_BUFFER, 0);
-
+
glEnable(GL_TEXTURE_2D);
-
+
if(transparent) {
glEnable(GL_BLEND);
glBlendFunc(GL_ONE, GL_ONE_MINUS_SRC_ALPHA);
@@ -1221,7 +1221,7 @@ public:
if(transparent)
glDisable(GL_BLEND);
-
+
glBindTexture(GL_TEXTURE_2D, 0);
glDisable(GL_TEXTURE_2D);
@@ -1237,12 +1237,12 @@ public:
{
if(task->type == DeviceTask::PATH_TRACE) {
RenderTile tile;
-
+
bool branched = task->integrator_branched;
/* Upload Bindless Mapping */
load_bindless_mapping();
-
+
/* keep rendering tiles until done */
while(task->acquire_tile(this, tile)) {
int start_sample = tile.start_sample;
@@ -1379,7 +1379,7 @@ void device_cuda_info(vector<DeviceInfo>& devices)
fprintf(stderr, "CUDA cuDeviceGetCount: %s\n", cuewErrorString(result));
return;
}
-
+
vector<DeviceInfo> display_devices;
for(int num = 0; num < count; num++) {
More information about the Bf-blender-cvs
mailing list