Fix warnings and remove casts by adding copy_vx_vx_uchar() functions.
[blender.git] / source / blender / blenkernel / intern / DerivedMesh.c
index e71cfca4e5b0cc3ddfb0c800a45f24f2702a82d4..4cf9885c716796673be2194c119931053072c50b 100644 (file)
@@ -1561,8 +1561,8 @@ void DM_update_weight_mcol(
                        ml = mloop + mp->loopstart;
 
                        for (j = 0; j < mp->totloop; j++, ml++, l_index++) {
-                               copy_v4_v4_char((char *)&wtcol_l[l_index],
-                                               (char *)&wtcol_v[ml->v]);
+                               copy_v4_v4_uchar(&wtcol_l[l_index][0],
+                                                &wtcol_v[ml->v][0]);
                        }
                }
                MEM_freeN(wtcol_v);
@@ -3453,7 +3453,7 @@ void DM_draw_attrib_vertex(DMVertexAttribs *attribs, int a, int index, int vert,
 
                if (attribs->mcol[b].array) {
                        const MLoopCol *cp = &attribs->mcol[b].array[loop];
-                       copy_v4_v4_char((char *)col, &cp->r);
+                       copy_v4_v4_uchar(col, &cp->r);
                }
                else {
                        col[0] = 0; col[1] = 0; col[2] = 0; col[3] = 0;