paint: cleanup
This commit is contained in:
@@ -5,7 +5,7 @@
|
||||
void export_glb_run(char *path, mesh_object_t_array_t *paint_objects);
|
||||
#endif
|
||||
|
||||
void export_mesh_run(char *path, mesh_object_t_array_t *paint_objects, bool apply_disp, bool merge_vertices) {
|
||||
void export_mesh_run(char *path, mesh_object_t_array_t *paint_objects, bool merge_vertices) {
|
||||
if (paint_objects == NULL) {
|
||||
paint_objects = g_project->_->paint_objects;
|
||||
}
|
||||
@@ -14,7 +14,7 @@ void export_mesh_run(char *path, mesh_object_t_array_t *paint_objects, bool appl
|
||||
export_obj_run_sculpt(path, paint_objects);
|
||||
}
|
||||
else if (merge_vertices) {
|
||||
export_obj_run(path, paint_objects, apply_disp);
|
||||
export_obj_run(path, paint_objects);
|
||||
}
|
||||
else {
|
||||
export_obj_run_fast(path, paint_objects);
|
||||
|
||||
@@ -7,7 +7,7 @@ static void export_obj_write_string(u8_array_t *out, char *str) {
|
||||
}
|
||||
}
|
||||
|
||||
void export_obj_run(char *path, mesh_object_t_array_t *paint_objects, bool apply_disp) {
|
||||
void export_obj_run(char *path, mesh_object_t_array_t *paint_objects) {
|
||||
u8_array_t *o = u8_array_create_from_raw((u8[]){}, 0);
|
||||
export_obj_write_string(o, "# armorpaint.org\n");
|
||||
|
||||
@@ -85,19 +85,6 @@ void export_obj_run(char *path, mesh_object_t_array_t *paint_objects, bool apply
|
||||
ti++;
|
||||
}
|
||||
}
|
||||
if (apply_disp) {
|
||||
// let height: buffer_t = gpu_get_texture_pixels(layers[0].texpaint_pack);
|
||||
// let res: i32 = layers[0].texpaint_pack.width;
|
||||
// let strength: f32 = 0.1;
|
||||
// for (let i: i32 = 0; i < len; ++i) {
|
||||
// let x: i32 = math_floor(texa2[i * 2 ] / 32767 * res);
|
||||
// let y: i32 = math_floor((1.0 - texa2[i * 2 + 1] / 32767) * res);
|
||||
// let h: f32 = (1.0 - height.get((y * res + x) * 4 + 3) / 255) * strength;
|
||||
// posa2[i * 3 ] -= math_floor(nora2[i * 3 ] * inv * h / sc);
|
||||
// posa2[i * 3 + 1] -= math_floor(nora2[i * 3 + 1] * inv * h / sc);
|
||||
// posa2[i * 3 + 2] -= math_floor(nora2[i * 3 + 2] * inv * h / sc);
|
||||
// }
|
||||
}
|
||||
|
||||
export_obj_write_string(o, string("o %s\n", p->base->name));
|
||||
for (i32 i = 0; i < pi; ++i) {
|
||||
|
||||
Reference in New Issue
Block a user