[Bf-blender-cvs] [eacdc3d] cycles_kernel_split: Cycles kernel split: Indentation fixes in new kernel files

Sergey Sharybin noreply at git.blender.org
Thu May 7 17:24:27 CEST 2015


Commit: eacdc3d96ab52ddfdc45acb4b16cb914b13cc82f
Author: Sergey Sharybin
Date:   Thu May 7 20:23:54 2015 +0500
Branches: cycles_kernel_split
https://developer.blender.org/rBeacdc3d96ab52ddfdc45acb4b16cb914b13cc82f

Cycles kernel split: Indentation fixes in new kernel files

===================================================================

M	intern/cycles/kernel/kernel_DirectLighting.cl
M	intern/cycles/kernel/kernel_Holdout_Emission_Blurring_Pathtermination_AO.cl
M	intern/cycles/kernel/kernel_LampEmission.cl
M	intern/cycles/kernel/kernel_NextIterationSetUp.cl
M	intern/cycles/kernel/kernel_SceneIntersect.cl
M	intern/cycles/kernel/kernel_ShaderEval.cl
M	intern/cycles/kernel/kernel_ShadowBlocked.cl

===================================================================

diff --git a/intern/cycles/kernel/kernel_DirectLighting.cl b/intern/cycles/kernel/kernel_DirectLighting.cl
index e019961..7dd59ae 100644
--- a/intern/cycles/kernel/kernel_DirectLighting.cl
+++ b/intern/cycles/kernel/kernel_DirectLighting.cl
@@ -52,8 +52,8 @@
 __kernel void kernel_ocl_path_trace_DirectLighting(
 	ccl_global char *globals,
 	ccl_constant KernelData *data,
-	ccl_global char *shader_data,		    /* Required for direct lighting */
-	ccl_global char *shader_DL,			    /* Required for direct lighting */
+	ccl_global char *shader_data,           /* Required for direct lighting */
+	ccl_global char *shader_DL,             /* Required for direct lighting */
 	ccl_global uint *rng_coop,              /* Required for direct lighting */
 	ccl_global PathState *PathState_coop,   /* Required for direct lighting */
 	ccl_global int *ISLamp_coop,            /* Required for direct lighting */
@@ -89,10 +89,10 @@ __kernel void kernel_ocl_path_trace_DirectLighting(
 	if(ray_index != QUEUE_EMPTY_SLOT) {
 #endif
 		if(IS_STATE(ray_state, ray_index, RAY_ACTIVE)) {
-    		/* Load kernel globals structure and ShaderData structure */
-    		KernelGlobals *kg = (KernelGlobals *)globals;
-    		ShaderData *sd = (ShaderData *)shader_data;
-    		ShaderData *sd_DL  = (ShaderData *)shader_DL;
+			/* Load kernel globals structure and ShaderData structure */
+			KernelGlobals *kg = (KernelGlobals *)globals;
+			ShaderData *sd = (ShaderData *)shader_data;
+			ShaderData *sd_DL  = (ShaderData *)shader_DL;
 
 			ccl_global PathState *state = &PathState_coop[ray_index];
 
diff --git a/intern/cycles/kernel/kernel_Holdout_Emission_Blurring_Pathtermination_AO.cl b/intern/cycles/kernel/kernel_Holdout_Emission_Blurring_Pathtermination_AO.cl
index 3adac2e..1fc1f48 100644
--- a/intern/cycles/kernel/kernel_Holdout_Emission_Blurring_Pathtermination_AO.cl
+++ b/intern/cycles/kernel/kernel_Holdout_Emission_Blurring_Pathtermination_AO.cl
@@ -75,7 +75,7 @@
 __kernel void kernel_ocl_path_trace_holdout_emission_blurring_pathtermination_AO(
 	ccl_global char *globals,
 	ccl_constant KernelData *data,
-	ccl_global char *shader_data,				/* Required throughout the kernel except probabilistic path termination and AO */
+	ccl_global char *shader_data,               /* Required throughout the kernel except probabilistic path termination and AO */
 	ccl_global float *per_sample_output_buffers,
 	ccl_global uint *rng_coop,                  /* Required for "kernel_write_data_passes" and AO */
 	ccl_global float3 *throughput_coop,         /* Required for handling holdout material and AO */
diff --git a/intern/cycles/kernel/kernel_LampEmission.cl b/intern/cycles/kernel/kernel_LampEmission.cl
index 00fb8b4..0322a70 100644
--- a/intern/cycles/kernel/kernel_LampEmission.cl
+++ b/intern/cycles/kernel/kernel_LampEmission.cl
@@ -43,7 +43,7 @@
 __kernel void kernel_ocl_path_trace_LampEmission(
 	ccl_global char *globals,
 	ccl_constant KernelData *data,
-	ccl_global char *shader_data,				/* Required for lamp emission */
+	ccl_global char *shader_data,               /* Required for lamp emission */
 	ccl_global float3 *throughput_coop,         /* Required for lamp emission */
 	PathRadiance *PathRadiance_coop, /* Required for lamp emission */
 	ccl_global Ray *Ray_coop,                   /* Required for lamp emission */
@@ -90,9 +90,9 @@ __kernel void kernel_ocl_path_trace_LampEmission(
 	}
 
 	if(IS_STATE(ray_state, ray_index, RAY_ACTIVE) || IS_STATE(ray_state, ray_index, RAY_HIT_BACKGROUND)) {
-	    KernelGlobals *kg = (KernelGlobals *)globals;
-	    ShaderData *sd = (ShaderData *)shader_data;
-	    PathRadiance *L = &PathRadiance_coop[ray_index];
+		KernelGlobals *kg = (KernelGlobals *)globals;
+		ShaderData *sd = (ShaderData *)shader_data;
+		PathRadiance *L = &PathRadiance_coop[ray_index];
 
 		float3 throughput = throughput_coop[ray_index];
 		Ray ray = Ray_coop[ray_index];
diff --git a/intern/cycles/kernel/kernel_NextIterationSetUp.cl b/intern/cycles/kernel/kernel_NextIterationSetUp.cl
index f7c49fb..3c06520 100644
--- a/intern/cycles/kernel/kernel_NextIterationSetUp.cl
+++ b/intern/cycles/kernel/kernel_NextIterationSetUp.cl
@@ -64,7 +64,7 @@
 __kernel void kernel_ocl_path_trace_SetupNextIteration(
 	ccl_global char *globals,
 	ccl_constant KernelData *data,
-	ccl_global char *shader_data,				/* Required for setting up ray for next iteration */
+	ccl_global char *shader_data,               /* Required for setting up ray for next iteration */
 	ccl_global uint *rng_coop,                  /* Required for setting up ray for next iteration */
 	ccl_global float3 *throughput_coop,         /* Required for setting up ray for next iteration */
 	PathRadiance *PathRadiance_coop, /* Required for setting up ray for next iteration */
diff --git a/intern/cycles/kernel/kernel_SceneIntersect.cl b/intern/cycles/kernel/kernel_SceneIntersect.cl
index fa08828..4ee44ab 100644
--- a/intern/cycles/kernel/kernel_SceneIntersect.cl
+++ b/intern/cycles/kernel/kernel_SceneIntersect.cl
@@ -69,7 +69,7 @@ __kernel void kernel_ocl_path_trace_SceneIntersect(
 	ccl_global uint *rng_coop,
 	ccl_global Ray *Ray_coop,                   /* Required for scene_intersect */
 	ccl_global PathState *PathState_coop,       /* Required for scene_intersect */
-	Intersection *Intersection_coop, /* Required for scene_intersect */
+	Intersection *Intersection_coop,            /* Required for scene_intersect */
 	ccl_global char *ray_state,                 /* Denotes the state of each ray */
 	int sw, int sh,
 	ccl_global int *Queue_data,                 /* Memory for queues */
diff --git a/intern/cycles/kernel/kernel_ShaderEval.cl b/intern/cycles/kernel/kernel_ShaderEval.cl
index 620b93f..622fb88 100644
--- a/intern/cycles/kernel/kernel_ShaderEval.cl
+++ b/intern/cycles/kernel/kernel_ShaderEval.cl
@@ -77,10 +77,10 @@ __kernel void kernel_ocl_path_trace_ShaderEvaluation(
 	if(ray_index == QUEUE_EMPTY_SLOT)
 		return;
 
-    /* Continue on with shader evaluation */
+	/* Continue on with shader evaluation */
 	if(IS_STATE(ray_state, ray_index, RAY_ACTIVE)) {
-	    KernelGlobals *kg = (KernelGlobals *)globals;
-	    ShaderData *sd = (ShaderData *)shader_data;
+		KernelGlobals *kg = (KernelGlobals *)globals;
+		ShaderData *sd = (ShaderData *)shader_data;
 		Intersection *isect = &Intersection_coop[ray_index];
 		ccl_global uint *rng = &rng_coop[ray_index];
 		ccl_global PathState *state = &PathState_coop[ray_index];
diff --git a/intern/cycles/kernel/kernel_ShadowBlocked.cl b/intern/cycles/kernel/kernel_ShadowBlocked.cl
index beb5ada..74632e5 100644
--- a/intern/cycles/kernel/kernel_ShadowBlocked.cl
+++ b/intern/cycles/kernel/kernel_ShadowBlocked.cl
@@ -50,7 +50,7 @@
 __kernel void kernel_ocl_path_trace_ShadowBlocked_DirectLighting(
 	ccl_global char *globals,
 	ccl_constant KernelData *data,
-	ccl_global char *shader_shadow,				/* Required for shadow blocked */
+	ccl_global char *shader_shadow,             /* Required for shadow blocked */
 	ccl_global PathState *PathState_coop,       /* Required for shadow blocked */
 	ccl_global Ray *LightRay_dl_coop,           /* Required for direct lighting's shadow blocked */
 	ccl_global Ray *LightRay_ao_coop,           /* Required for AO's shadow blocked */
@@ -103,24 +103,24 @@ __kernel void kernel_ocl_path_trace_ShadowBlocked_DirectLighting(
 		return;
 
 	if(IS_FLAG(ray_state, ray_index, RAY_SHADOW_RAY_CAST_DL) || IS_FLAG(ray_state, ray_index, RAY_SHADOW_RAY_CAST_AO)) {
-        /* Load kernel global structure */
-        KernelGlobals *kg = (KernelGlobals *)globals;
-        ShaderData *sd_shadow  = (ShaderData *)shader_shadow;
+		/* Load kernel global structure */
+		KernelGlobals *kg = (KernelGlobals *)globals;
+		ShaderData *sd_shadow  = (ShaderData *)shader_shadow;
 
-        ccl_global PathState *state = &PathState_coop[ray_index];
-        ccl_global Ray *light_ray_dl_global = &LightRay_dl_coop[ray_index];
-        ccl_global Ray *light_ray_ao_global = &LightRay_ao_coop[ray_index];
-        Intersection *isect_ao_global = &Intersection_coop_AO[ray_index];
-	    Intersection *isect_dl_global = &Intersection_coop_DL[ray_index];
+		ccl_global PathState *state = &PathState_coop[ray_index];
+		ccl_global Ray *light_ray_dl_global = &LightRay_dl_coop[ray_index];
+		ccl_global Ray *light_ray_ao_global = &LightRay_ao_coop[ray_index];
+		Intersection *isect_ao_global = &Intersection_coop_AO[ray_index];
+		Intersection *isect_dl_global = &Intersection_coop_DL[ray_index];
 
-        ccl_global Ray *light_ray_global = shadow_blocked_type == RAY_SHADOW_RAY_CAST_AO ? light_ray_ao_global : light_ray_dl_global;
-        Intersection *isect_global = RAY_SHADOW_RAY_CAST_AO ? isect_ao_global : isect_dl_global;
+		ccl_global Ray *light_ray_global = shadow_blocked_type == RAY_SHADOW_RAY_CAST_AO ? light_ray_ao_global : light_ray_dl_global;
+		Intersection *isect_global = RAY_SHADOW_RAY_CAST_AO ? isect_ao_global : isect_dl_global;
 
-	    float3 shadow;
-	    update_path_radiance = !(shadow_blocked(kg, state, light_ray_global, &shadow, sd_shadow, isect_global));
+		float3 shadow;
+		update_path_radiance = !(shadow_blocked(kg, state, light_ray_global, &shadow, sd_shadow, isect_global));
 
-	    /* We use light_ray_global's P and t to store shadow and update_path_radiance */
-	    light_ray_global->P = shadow;
-	    light_ray_global->t = update_path_radiance;
+		/* We use light_ray_global's P and t to store shadow and update_path_radiance */
+		light_ray_global->P = shadow;
+		light_ray_global->t = update_path_radiance;
 	}
 }




More information about the Bf-blender-cvs mailing list