diff options
author | Campbell Barton <ideasman42@gmail.com> | 2021-10-12 09:52:35 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2021-10-12 09:55:02 +0300 |
commit | c1c6c11ca6c5f4cd775b787910fe69119b054af2 (patch) | |
tree | e41bb7057e27810c18ca6cc23e40ee48c3e814b4 /intern | |
parent | a91c6f1804e9ce07e9f751bc1c3c05751da7607a (diff) |
Cleanup: spelling in comments
Diffstat (limited to 'intern')
-rw-r--r-- | intern/cycles/bvh/bvh.h | 2 | ||||
-rw-r--r-- | intern/cycles/kernel/bvh/bvh_util.h | 2 | ||||
-rw-r--r-- | intern/cycles/kernel/closure/bsdf.h | 2 | ||||
-rw-r--r-- | intern/cycles/kernel/closure/bsdf_principled_diffuse.h | 4 | ||||
-rw-r--r-- | intern/cycles/kernel/closure/bssrdf.h | 6 | ||||
-rw-r--r-- | intern/cycles/kernel/integrator/integrator_shade_volume.h | 2 | ||||
-rw-r--r-- | intern/cycles/kernel/integrator/integrator_subsurface_random_walk.h | 12 | ||||
-rw-r--r-- | intern/cycles/kernel/shaders/node_image_texture.osl | 4 | ||||
-rw-r--r-- | intern/cycles/kernel/svm/svm_image.h | 4 |
9 files changed, 19 insertions, 19 deletions
diff --git a/intern/cycles/bvh/bvh.h b/intern/cycles/bvh/bvh.h index d9e2ad9526c..b222dfb14ed 100644 --- a/intern/cycles/bvh/bvh.h +++ b/intern/cycles/bvh/bvh.h @@ -52,7 +52,7 @@ struct PackedBVH { array<int> object_node; /* primitive type - triangle or strand */ array<int> prim_type; - /* visibility visibilitys for primitives */ + /* Visibility visibilities for primitives. */ array<uint> prim_visibility; /* mapping from BVH primitive index to true primitive index, as primitives * may be duplicated due to spatial splits. -1 for instances. */ diff --git a/intern/cycles/kernel/bvh/bvh_util.h b/intern/cycles/kernel/bvh/bvh_util.h index e16da9755f2..d143fe4aeab 100644 --- a/intern/cycles/kernel/bvh/bvh_util.h +++ b/intern/cycles/kernel/bvh/bvh_util.h @@ -72,7 +72,7 @@ ccl_device_inline float3 ray_offset(float3 P, float3 Ng) } #if defined(__VOLUME_RECORD_ALL__) || (defined(__SHADOW_RECORD_ALL__) && defined(__KERNEL_CPU__)) -/* ToDo: Move to another file? */ +/* TODO: Move to another file? */ ccl_device int intersections_compare(const void *a, const void *b) { const Intersection *isect_a = (const Intersection *)a; diff --git a/intern/cycles/kernel/closure/bsdf.h b/intern/cycles/kernel/closure/bsdf.h index 87aa6339f80..bb80b9636bb 100644 --- a/intern/cycles/kernel/closure/bsdf.h +++ b/intern/cycles/kernel/closure/bsdf.h @@ -654,7 +654,7 @@ ccl_device_inline ccl_device void bsdf_blur(const KernelGlobals *kg, ShaderClosure *sc, float roughness) { - /* ToDo: do we want to blur volume closures? */ + /* TODO: do we want to blur volume closures? */ #ifdef __SVM__ switch (sc->type) { case CLOSURE_BSDF_MICROFACET_MULTI_GGX_ID: diff --git a/intern/cycles/kernel/closure/bsdf_principled_diffuse.h b/intern/cycles/kernel/closure/bsdf_principled_diffuse.h index 04963ca1dc5..52a37eafd9f 100644 --- a/intern/cycles/kernel/closure/bsdf_principled_diffuse.h +++ b/intern/cycles/kernel/closure/bsdf_principled_diffuse.h @@ -91,7 +91,7 @@ ccl_device float3 bsdf_principled_diffuse_compute_brdf( return make_float3(value, value, value); } -/* Compute Fresnel at entry point, to be compbined with PRINCIPLED_DIFFUSE_LAMBERT_EXIT +/* Compute Fresnel at entry point, to be combined with #PRINCIPLED_DIFFUSE_LAMBERT_EXIT * at the exit point to get the complete BSDF. */ ccl_device_inline float bsdf_principled_diffuse_compute_entry_fresnel(const float NdotV) { @@ -99,7 +99,7 @@ ccl_device_inline float bsdf_principled_diffuse_compute_entry_fresnel(const floa return (1.0f - 0.5f * FV); } -/* Ad-hoc weight adjusment to avoid retro-reflection taking away half the +/* Ad-hoc weight adjustment to avoid retro-reflection taking away half the * samples from BSSRDF. */ ccl_device_inline float bsdf_principled_diffuse_retro_reflection_sample_weight( PrincipledDiffuseBsdf *bsdf, const float3 I) diff --git a/intern/cycles/kernel/closure/bssrdf.h b/intern/cycles/kernel/closure/bssrdf.h index d2f8af7910c..07415c53ec5 100644 --- a/intern/cycles/kernel/closure/bssrdf.h +++ b/intern/cycles/kernel/closure/bssrdf.h @@ -136,10 +136,10 @@ ccl_device float bssrdf_burley_eval(const float d, float r) /* Burley reflectance profile, equation (3). * * NOTES: - * - Surface albedo is already included into sc->weight, no need to + * - Surface albedo is already included into `sc->weight`, no need to * multiply by this term here. * - This is normalized diffuse model, so the equation is multiplied - * by 2*pi, which also matches cdf(). + * by `2*pi`, which also matches `cdf()`. */ float exp_r_3_d = expf(-r / (3.0f * d)); float exp_r_d = exp_r_3_d * exp_r_3_d * exp_r_3_d; @@ -288,7 +288,7 @@ ccl_device int bssrdf_setup(ShaderData *sd, Bssrdf *bssrdf, ClosureType type, co bsdf->roughness = bssrdf->roughness; flag |= bsdf_principled_diffuse_setup(bsdf, PRINCIPLED_DIFFUSE_RETRO_REFLECTION); - /* Ad-hoc weight adjusment to avoid retro-reflection taking away half the + /* Ad-hoc weight adjustment to avoid retro-reflection taking away half the * samples from BSSRDF. */ bsdf->sample_weight *= bsdf_principled_diffuse_retro_reflection_sample_weight(bsdf, sd->I); } diff --git a/intern/cycles/kernel/integrator/integrator_shade_volume.h b/intern/cycles/kernel/integrator/integrator_shade_volume.h index dac3efb3996..aa4c652c037 100644 --- a/intern/cycles/kernel/integrator/integrator_shade_volume.h +++ b/intern/cycles/kernel/integrator/integrator_shade_volume.h @@ -232,7 +232,7 @@ ccl_device void volume_shadow_heterogeneous(INTEGRATOR_STATE_ARGS, * because `exp(a)*exp(b) = exp(a+b)`, also do a quick #VOLUME_THROUGHPUT_EPSILON * check then. */ sum += (-sigma_t * dt); - if ((i & 0x07) == 0) { /* ToDo: Other interval? */ + if ((i & 0x07) == 0) { /* TODO: Other interval? */ tp = *throughput * exp3(sum); /* stop if nearly all light is blocked */ diff --git a/intern/cycles/kernel/integrator/integrator_subsurface_random_walk.h b/intern/cycles/kernel/integrator/integrator_subsurface_random_walk.h index cffc53bf270..d4935b0ce4a 100644 --- a/intern/cycles/kernel/integrator/integrator_subsurface_random_walk.h +++ b/intern/cycles/kernel/integrator/integrator_subsurface_random_walk.h @@ -253,7 +253,7 @@ ccl_device_inline bool subsurface_random_walk(INTEGRATOR_STATE_ARGS, bool have_opposite_interface = false; float opposite_distance = 0.0f; - /* Todo: Disable for alpha>0.999 or so? */ + /* TODO: Disable for `alpha > 0.999` or so? */ /* Our heuristic, a compromise between guiding and classic. */ const float guided_fraction = 1.0f - fmaxf(0.5f, powf(fabsf(anisotropy), 0.125f)); @@ -295,7 +295,7 @@ ccl_device_inline bool subsurface_random_walk(INTEGRATOR_STATE_ARGS, float sample_sigma_t = volume_channel_get(sigma_t, channel); float randt = path_state_rng_1D(kg, &rng_state, PRNG_SCATTER_DISTANCE); - /* We need the result of the raycast to compute the full guided PDF, so just remember the + /* We need the result of the ray-cast to compute the full guided PDF, so just remember the * relevant terms to avoid recomputing them later. */ float backward_fraction = 0.0f; float forward_pdf_factor = 0.0f; @@ -330,7 +330,7 @@ ccl_device_inline bool subsurface_random_walk(INTEGRATOR_STATE_ARGS, float hg_pdf; if (guided) { cos_theta = sample_phase_dwivedi(diffusion_length, phase_log, scatter_u); - /* The backwards guiding distribution is just mirrored along sd->N, so swapping the + /* The backwards guiding distribution is just mirrored along `sd->N`, so swapping the * sign here is enough to sample from that instead. */ if (guide_backward) { cos_theta = -cos_theta; @@ -358,7 +358,7 @@ ccl_device_inline bool subsurface_random_walk(INTEGRATOR_STATE_ARGS, /* Prepare distance sampling. * For the backwards case, this also needs the sign swapped since now directions against - * sd->N (and therefore with negative cos_theta) are preferred. */ + * `sd->N` (and therefore with negative cos_theta) are preferred. */ forward_stretching = (1.0f - cos_theta / diffusion_length); backward_stretching = (1.0f + cos_theta / diffusion_length); if (guided) { @@ -369,10 +369,10 @@ ccl_device_inline bool subsurface_random_walk(INTEGRATOR_STATE_ARGS, /* Sample direction along ray. */ float t = -logf(1.0f - randt) / sample_sigma_t; - /* On the first bounce, we use the raycast to check if the opposite side is nearby. + /* On the first bounce, we use the ray-cast to check if the opposite side is nearby. * If yes, we will later use backwards guided sampling in order to have a decent * chance of connecting to it. - * Todo: Maybe use less than 10 times the mean free path? */ + * TODO: Maybe use less than 10 times the mean free path? */ ray.t = (bounce == 0) ? max(t, 10.0f / (min3(sigma_t))) : t; scene_intersect_local(kg, &ray, &ss_isect, object, NULL, 1); hit = (ss_isect.num_hits > 0); diff --git a/intern/cycles/kernel/shaders/node_image_texture.osl b/intern/cycles/kernel/shaders/node_image_texture.osl index 9e2ef84c872..56fcc47a011 100644 --- a/intern/cycles/kernel/shaders/node_image_texture.osl +++ b/intern/cycles/kernel/shaders/node_image_texture.osl @@ -143,10 +143,10 @@ shader node_image_texture(int use_mapping = 0, * in between we blend between two textures, and in the middle we a blend * between three textures. * - * the Nxyz values are the barycentric coordinates in an equilateral + * the `Nxyz` values are the barycentric coordinates in an equilateral * triangle, which in case of blending, in the middle has a smaller * equilateral triangle where 3 textures blend. this divides things into - * 7 zones, with an if () test for each zone */ + * 7 zones, with an if () test for each zone. */ vector weight = vector(0.0, 0.0, 0.0); float blend = projection_blend; diff --git a/intern/cycles/kernel/svm/svm_image.h b/intern/cycles/kernel/svm/svm_image.h index a344f36977a..ce70109392b 100644 --- a/intern/cycles/kernel/svm/svm_image.h +++ b/intern/cycles/kernel/svm/svm_image.h @@ -142,10 +142,10 @@ ccl_device_noinline void svm_node_tex_image_box(const KernelGlobals *kg, * in between we blend between two textures, and in the middle we a blend * between three textures. * - * the Nxyz values are the barycentric coordinates in an equilateral + * The `Nxyz` values are the barycentric coordinates in an equilateral * triangle, which in case of blending, in the middle has a smaller * equilateral triangle where 3 textures blend. this divides things into - * 7 zones, with an if() test for each zone */ + * 7 zones, with an if() test for each zone. */ float3 weight = make_float3(0.0f, 0.0f, 0.0f); float blend = __int_as_float(node.w); |