Cycles Hair: Corrected own stochastic hair rng mistake and removed an unnecessary padding variable
- Corrected the Sobol dimension and removed a pad variable in Curve Struct.
This commit is contained in:
@@ -258,7 +258,7 @@ __device float4 kernel_path_progressive(KernelGlobals *kg, RNG *rng, int sample,
|
||||
difl = kernel_data.curve_kernel_data.minimum_width * len(pixdiff) * 0.5f;
|
||||
}
|
||||
float extmax = kernel_data.curve_kernel_data.maximum_width;
|
||||
float rng_hair_seed = path_rng(kg, rng, sample, rng_offset + PRNG_STOCHASTIC_HAIR);
|
||||
float rng_hair_seed = path_rng(kg, rng, sample, rng_offset + PRNG_HAIR);
|
||||
uint lcg_state = lcg_init(rng_hair_seed);
|
||||
|
||||
bool hit = scene_intersect(kg, &ray, visibility, &isect, &lcg_state, difl, extmax);
|
||||
@@ -930,7 +930,7 @@ __device float4 kernel_path_non_progressive(KernelGlobals *kg, RNG *rng, int sam
|
||||
difl = kernel_data.curve_kernel_data.minimum_width * len(pixdiff) * 0.5f;
|
||||
}
|
||||
float extmax = kernel_data.curve_kernel_data.maximum_width;
|
||||
float rng_hair_seed = path_rng(kg, rng, sample, rng_offset + PRNG_STOCHASTIC_HAIR);
|
||||
float rng_hair_seed = path_rng(kg, rng, sample, rng_offset + PRNG_HAIR);
|
||||
uint lcg_state = lcg_init(rng_hair_seed);
|
||||
|
||||
if(!scene_intersect(kg, &ray, visibility, &isect, &lcg_state, difl, extmax)) {
|
||||
|
@@ -159,8 +159,8 @@ enum PathTraceDimension {
|
||||
PRNG_LIGHT_V = 5,
|
||||
PRNG_LIGHT_F = 6,
|
||||
PRNG_TERMINATE = 7,
|
||||
PRNG_BOUNCE_NUM = 8,
|
||||
PRNG_STOCHASTIC_HAIR = 9
|
||||
PRNG_HAIR = 8,
|
||||
PRNG_BOUNCE_NUM = 9
|
||||
};
|
||||
|
||||
/* these flags values correspond to raytypes in osl.cpp, so keep them in sync!
|
||||
|
@@ -55,7 +55,6 @@ public:
|
||||
int first_key;
|
||||
int num_keys;
|
||||
uint shader;
|
||||
uint pad;
|
||||
|
||||
int num_segments() { return num_keys - 1; }
|
||||
};
|
||||
|
Reference in New Issue
Block a user