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:
authorPablo Dobarro <pablodp606@gmail.com>2020-12-02 00:22:13 +0300
committerPablo Dobarro <pablodp606@gmail.com>2020-12-04 00:46:32 +0300
commit92e44ce67cadff6f9e39bf9e3e20da81935f2f54 (patch)
tree968ddb64f6a9c2d5a5794e0c3e3f2551d6851574 /source/blender/editors/space_info
parent82e401031fd12962cdf61e5334197aa013f65ec9 (diff)
UI: Add sculpt stats to statusbar
This was missing from D9623. Now the same sculpt scene stats are also displayed in the status bar. Reviewed By: sergey Differential Revision: https://developer.blender.org/D9700
Diffstat (limited to 'source/blender/editors/space_info')
-rw-r--r--source/blender/editors/space_info/info_stats.c23
1 files changed, 17 insertions, 6 deletions
diff --git a/source/blender/editors/space_info/info_stats.c b/source/blender/editors/space_info/info_stats.c
index 890bb8a64bc..ffac5c982d6 100644
--- a/source/blender/editors/space_info/info_stats.c
+++ b/source/blender/editors/space_info/info_stats.c
@@ -559,12 +559,23 @@ static void get_stats_string(
stats_fmt->totgpstroke,
stats_fmt->totgppoint);
}
- else if (stats_is_object_dynamic_topology_sculpt(ob)) {
- *ofs += BLI_snprintf(info + *ofs,
- len - *ofs,
- TIP_("Verts:%s | Tris:%s"),
- stats_fmt->totvert,
- stats_fmt->tottri);
+ else if (ob && (object_mode & OB_MODE_SCULPT)) {
+ if (stats_is_object_dynamic_topology_sculpt(ob)) {
+ *ofs += BLI_snprintf(info + *ofs,
+ len - *ofs,
+ TIP_("Verts:%s | Tris:%s"),
+ stats_fmt->totvert,
+ stats_fmt->tottri);
+ }
+ else {
+ *ofs += BLI_snprintf(info + *ofs,
+ len - *ofs,
+ TIP_("Verts:%s/%s | Faces:%s/%s"),
+ stats_fmt->totvertsculpt,
+ stats_fmt->totvert,
+ stats_fmt->totfacesculpt,
+ stats_fmt->totface);
+ }
}
else {
*ofs += BLI_snprintf(info + *ofs,