Progress
This commit is contained in:
parent
c0f754d9b1
commit
846d8ef856
|
@ -41,7 +41,7 @@ typedef struct PBVH_GPU_Args {
|
|||
|
||||
struct BMesh *bm;
|
||||
const struct Mesh *me;
|
||||
const struct MVert *mvert;
|
||||
const float (*mesh_positions)[3];
|
||||
const struct MLoop *mloop;
|
||||
const struct MPoly *mpoly;
|
||||
int mesh_verts_num, mesh_faces_num, mesh_grids_num;
|
||||
|
|
|
@ -307,7 +307,7 @@ struct PBVHBatches {
|
|||
|
||||
if (!(mp->flag & ME_SMOOTH)) {
|
||||
smooth = true;
|
||||
BKE_mesh_calc_poly_normal(mp, args->mloop + mp->loopstart, args->mvert, fno);
|
||||
BKE_mesh_calc_poly_normal(mp, args->mloop + mp->loopstart, args->mesh_positions, fno);
|
||||
normal_float_to_short_v3(no, fno);
|
||||
}
|
||||
else {
|
||||
|
@ -537,7 +537,8 @@ struct PBVHBatches {
|
|||
case CD_PBVH_CO_TYPE:
|
||||
foreach_faces(
|
||||
[&](int /*buffer_i*/, int /*tri_i*/, int vertex_i, const MLoopTri * /*tri*/) {
|
||||
*static_cast<float3 *>(GPU_vertbuf_raw_step(&access)) = args->mvert[vertex_i].co;
|
||||
*static_cast<float3 *>(
|
||||
GPU_vertbuf_raw_step(&access)) = args->mesh_positions[vertex_i];
|
||||
});
|
||||
break;
|
||||
case CD_PBVH_NO_TYPE:
|
||||
|
|
Loading…
Reference in New Issue