Changeset View
Changeset View
Standalone View
Standalone View
intern/cycles/kernel/integrator/mnee.h
| Show First 20 Lines • Show All 273 Lines • ▼ Show 20 Lines | ccl_device_forceinline void mnee_setup_manifold_vertex(KernelGlobals kg, | ||||
| /* Geometric information. */ | /* Geometric information. */ | ||||
| vtx->uv = make_float2(isect->u, isect->v); | vtx->uv = make_float2(isect->u, isect->v); | ||||
| vtx->object = sd_vtx->object; | vtx->object = sd_vtx->object; | ||||
| vtx->prim = sd_vtx->prim; | vtx->prim = sd_vtx->prim; | ||||
| vtx->shader = sd_vtx->shader; | vtx->shader = sd_vtx->shader; | ||||
| } | } | ||||
| /* Compute constraint derivatives. */ | /* Compute constraint derivatives. */ | ||||
| ccl_device_forceinline bool mnee_compute_constraint_derivatives( | |||||
| # if defined(__KERNEL_METAL__) | |||||
| /* Temporary workaround for front-end compilation bug (incorrect MNEE rendering when this is | |||||
| * inlined). */ | |||||
| __attribute__((noinline)) | |||||
| # else | |||||
| ccl_device_forceinline | |||||
| # endif | |||||
| bool mnee_compute_constraint_derivatives( | |||||
| int vertex_count, | int vertex_count, | ||||
| ccl_private ManifoldVertex *vertices, | ccl_private ManifoldVertex *vertices, | ||||
| ccl_private const float3 &surface_sample_pos, | ccl_private const float3 &surface_sample_pos, | ||||
| const bool light_fixed_direction, | const bool light_fixed_direction, | ||||
| const float3 light_sample) | const float3 light_sample) | ||||
| { | { | ||||
| for (int vi = 0; vi < vertex_count; vi++) { | for (int vi = 0; vi < vertex_count; vi++) { | ||||
| ccl_private ManifoldVertex &v = vertices[vi]; | ccl_private ManifoldVertex &v = vertices[vi]; | ||||
| ▲ Show 20 Lines • Show All 810 Lines • Show Last 20 Lines | |||||