Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2011-02-10 12:29:31 +0300
committerCampbell Barton <ideasman42@gmail.com>2011-02-10 12:29:31 +0300
commit264c8c21623c3b011494e169f0571c410331e553 (patch)
tree042e28dfb51ea1a302569e93ea33d27de7088fcf /source/blender/makesrna/intern/rna_mesh_api.c
parent0356e3b69fa13660892036fa3950c7eb91d3c691 (diff)
mesh.validate() now returns True if any corrections were made.
tested that correcting invalid meshes works by generating random meshes and checking that only the first call to mesh.validate() makes changes. found 2 bugs in mesh validation. - face sorting array wasn't assigned correct indices. - removing invalid edges used wrong comparison.
Diffstat (limited to 'source/blender/makesrna/intern/rna_mesh_api.c')
-rw-r--r--source/blender/makesrna/intern/rna_mesh_api.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/source/blender/makesrna/intern/rna_mesh_api.c b/source/blender/makesrna/intern/rna_mesh_api.c
index dd78e93835e..3090f8512e0 100644
--- a/source/blender/makesrna/intern/rna_mesh_api.c
+++ b/source/blender/makesrna/intern/rna_mesh_api.c
@@ -59,7 +59,10 @@ void RNA_api_mesh(StructRNA *srna)
RNA_def_function_flag(func, FUNC_USE_CONTEXT);
func= RNA_def_function(srna, "validate", "BKE_mesh_validate");
- RNA_def_function_ui_description(func, "validate geometry.");
+ RNA_def_function_ui_description(func, "validate geometry, return True when the mesh has had invalid geometry corrected/removed.");
+ parm= RNA_def_boolean(func, "verbose", 0, "Verbose", "Output information about the errors found");
+ parm= RNA_def_boolean(func, "result", 0, "Result", "");
+ RNA_def_function_return(func, parm);
}
#endif