NaturalIntelligence / imglab

To speedup and simplify image labeling/ annotation process with multiple supported formats.
https://solothought.com/imglab/
MIT License
985 stars 608 forks source link

Linted Code and Removed Tracking Lines From Workarea #131

Closed alextychan closed 6 years ago

alextychan commented 6 years ago

Purpose / Goal

Linted code and removed tracking lines from workarea.

Type

Please mention the type of PR

amitguptagwl commented 6 years ago

tracking lines are required. I'm considering that this commit is not to remove the feature.

alextychan commented 6 years ago

I've removed the tracking lines and added a mouse coordinate display on the side of the toolbar. As the tracking lines affect the performance of the application due to the constant re-rendering of the position indicator.

amitguptagwl commented 6 years ago

Tracking lines were not being used to display the mouse coordinates. Both have a different purpose. Tracking lines help to select the right point to start, especially in the case of rectangles.

alextychan commented 6 years ago

Hmm. When the shapes are selected, svg.js would show the surrounding points of the shape. Those points can then be interacted with.

So I am not sure why there's a need for tracking lines. Under what use case would it be useful?

amitguptagwl commented 6 years ago

There are 2 aspects;

  1. draw the rectangle then select the move tool to adjust start points. Then stretch it to properly cover the object

without tracking lines

  1. start drawing the rectangle from the right point with the help of tracking lines.

with tracking lines

alextychan commented 6 years ago

Both the examples above already work without the tracking lines. I think it's more consistent to just allow users to plot it using mouse clicks as the tracking lines don't provide additional merit. If you would still prefer there to be tracking lines then I'll add it back to the project.

amitguptagwl commented 6 years ago

Tracking lines are required to improve the user experience not to complete some functionality. They mainly help to draw rectangle boxes. A circle, polygon or other shapes may require other kinds of guide lines.

So, we can take the decision to provide a toggle button to enable/disable them on demand. We can limit it to rectangle shape only.

Another alternate can be, not sure how effective it is, to have a png as cursor containing crossing line. So we can change cursor style in case of rectangle shape.