Measureit Addon does not seem to produce simple measurement from point to point in edit mode
Closed, ResolvedPublic

Description

System Information
Operating system and graphics card
OS X 10.12.6
AMD Radio R9 M390 2048MB

Blender Version
Version 2.78(2.78 2017-02-27

Short description of error
Measureit add-on puts up GUI properly but will not show length of line between two points in edit mode.
(Of course, the error could be my lack of understanding of how to use Measureit...

Exact steps for others to reproduce the error

****NEW 11 Sep 2017 The geometry was all created by just adding meshes. The file represents years of not-quite-learning how to use Blender, and I am not surprised that there are multiple copies of some objects, considering the slap-dash manner it was put together over a period of years, if not decades. I very much appreciate your efforts! [[NOTE: I don't know the proper way to answer questions...so I hope you find this.]] *****NEW 11 Sep 2017

Probably the latter. :)
You have to hit the 'show' button.
In my opinion, this should be activated by default.

Joel Godin (FloridaJo) closed this task as Invalid.Aug 26 2017, 12:01 AM
Joel Godin (FloridaJo) claimed this task.
Nicholas Spies (nspies11) reopened this task as Open.EditedAug 29 2017, 1:45 AM

IN RE: T52545

My original complaint about Measureit was proven to be my own inexperience with it. Thanks for pointing out the simple solution.

However, the problem is deeper. I was able to reproduce the steps in the documentation video, but only on a fresh Blender file.

My object is to annotate a house plan, measured to great detail. Most of the objects in the file, including furniture, shelves, etc. have been joined in one of two ways (I don't know the terminology; perhaps I mean Join versus Group).

I have not been able to get Measureit to produce dimensioning on any of the objects in the file.

The only part of Measureit that does work on this house plan is the Mesh Debug feature, which displays vertex number and their positions when two points are selected in Edit Mode.

Is there some sort of limitation on objects that have been grouped or joined, even when they are ungrouped to select two points within a component.

Or does this represent some sort of corruption of the Blender file, which has been created fitfully over a period of years, with many different versions of Blender. In which case, I would like to know how to clean up my file so Measureit will work...

This time I have included the file in which Measureit fails to do dimensioning,

Yes, I see now.
Reopened.

nBurn (nBurn) added a subscriber: nBurn (nBurn).EditedSep 12 2017, 12:10 AM

Bah, didn't know this was reopened. Well this is definitely a weird issue. MeasureIt seems to work just fine if you add new geometry or annotations to the blend file, but fails with most of the existing geometry. I don't know of any limitation preventing MeasureIt from working with joined or grouped geometry. Did you use Archimesh or another addon to create the geometry or the stock "Add mesh" option?

I found what I believe is the source the problem. There appears to be an issue with MeasureIt when geometry is on different layers. When I moved all the geometry to the first layer all the measurements in the file work as intended. I'm not sure if this is related, but there also appears to be duplicates of most of the geometry scattered over different layers.

@nBurn (nBurn) you mean to enable measures of an object in a different layer of current layer?

The measure is one object only or the measure between two vertices of different objects?

@Nicholas Spies (nspies11) I was wrong, "HOUSE_WALLS" was the only mesh object that was duplicated. It looks like the duplicate (HOUSE_WALLS.001) is what most of the measurements were attached to. Also, to submit answers you can just enter them in the reply box at the bottom of this page. But if that is not working for some reason, editing the description works to.

@Antonio Vazquez (antoniov) I am not sure if layers are actually the source of this issue. I thought they were originally, but I have not yet found a way to reproduce this issue manually starting from a new scene and moving mesh objects to different layers. It could be that the attached blend file is corrupted in some way (it's at least an unusual setup with transform panels on both sides of the viewport).

What I found in testing was the measurements attached to "HOUSE_WALLS" and "HOUSE_WALLS.001" (in the attached blend file) do not work on layer 5 and they stay not working if those mesh objects are moved to any other layer besides layer 0. But if "HOUSE_WALLS" or "HOUSE_WALLS.001" get moved to layer 0, the measurements attached to them worked as intended, even if they were moved to different layers afterwards. Very strange.

@nBurn (nBurn) Yes, it's strange. I tried to replicate myself the problem of the layers and it was impossible. One idea I had.... the .blend are walls... not totally sure, but I shared some code in Archimesh for measures, so maybe the user created the wallls with Archimesh and then adapt it to MeasureIt... this is something to investigate.

@Antonio Vazquez (antoniov) According to the submitter this was not made with Archimesh, but the default add mesh tool. For some more strangeness, I noticed if I move the one of the HOUSE_WALLS objects from layer 0 back to layer 5 the measurements break again.

I did a more exhaustive test and opened "houseplan_24Aug17.blend" in Blender 2.78 and copied all the objects from that file into a seperate instance of 2.78 keeping the same layer organization and I'm not seeing the problems with MeasureIt anymore. The object and geometry count did go way up in the process:

From:
Verts: 3340 / Faces: 3240 / Tris: 6288 / Objects: 9 / Lamps: 2 / Mem: 13.57M

To:
Verts: 11272 / Faces: 10738 / Tris: 19982 / Objects: 63 / Lamps: 2 / Mem: 13.42M

My suspicion is something broke in the file itself when moving this between multiple different Blender versions and that what was causing issues. I'll leave this bug report open for a few more days and welcome any input, but if no one else raises any issues in that time I plan to close this as resolved.

I've attached my test version of the file made by copying the geometry into a new file (linked below) for reference.

Subject: Re: [developer.blender.org] [Created] T52545: Measureit Addon does not seem to produce simple measurement from point to point in edit mode

Apropos "My suspicion is something broke in the file itself when moving this between multiple different Blender versions and that what was causing issues."
I think that this is quite likely to be the reason that Measureit did not work on the house plan file. It WAS made with a large number of versions of Blender (and, as funky as the plan is, I did get a lot of utility for different arrangements of furniture, etc from it).

However this raises the question as to whether Blender, and in particular the recent versions of Blender, do a complete job of converting older files to the newest format, on the assumption that is explains the Measureit problem.

I missed an update on this again :( I need to check my email settings...

However this raises the question as to whether Blender, and in particular the recent versions of Blender, do a complete job of converting older files to the newest format, on the assumption that is explains the Measureit problem.

Yes, this is what I am suspecting, that the source of this issue may be with the way Blender loads older blend files, but I don't have enough familiarity with how Blender handles legacy blend files to say for certain.

MeasureIt works by storing its measurement data in a custom property (a 'MeasureGenerator') that gets added to the selected mesh objects. When measurement drawing is enabled (with the 'Show' option), MeasureIt searches every mesh object in the scene to see if they have this custom data. If the custom data is found, MeasureIt reads that data and uses it to draw measurements on the viewport.

The bug here doesn't seem to be with how MeasureIt stores data, but with how the stored data is accessed later on. Something about the 'houseplan_24Aug17' blend file you uploaded is preventing MeasureIt from being able to find/read the custom measurement properties.

nBurn (nBurn) added a comment.EditedSep 25 2017, 9:48 AM

I found the issue, it looks like this may be a bug with MeasureIt after all. The problem is MeasureIt only checks Scene layer visibility settings for determining whether or not to display measurements (measureit_main.py, lines 2014 through 2040). This becomes an issue if the "Scene lock" button to the right of the layer manager is disabled which allows screen layouts to have seperate layer visibility settings seperate from the scene layer settings. This is the case with the "houseplan_24Aug17.blend" file which has all the MeasureIt data stored on layer 6 which is not enabled in the scene's layer settings, but is enabled in the active "2-Model " screen layout settings. You can verify this by enabling the "Scene lock" button with "houseplan_24Aug17.blend" open in Blender.

@nBurn (nBurn) Can you fix it? I'm very busy with grease pencil now. If you cannot, let me know and I will take a look.

@Antonio Vazquez (antoniov) Sure. I have a rough idea for a fix.