Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[mesh] mesh frame editing part 3 - Edit mesh map tool (Request in QGIS) #6883

Closed
qgis-bot opened this issue Aug 18, 2021 · 0 comments · Fixed by #7732
Closed

[mesh] mesh frame editing part 3 - Edit mesh map tool (Request in QGIS) #6883

qgis-bot opened this issue Aug 18, 2021 · 0 comments · Fixed by #7732
Assignees
Labels
3.22 QGIS 3.22 new features Editing Mesh
Milestone

Comments

@qgis-bot
Copy link
Collaborator

Request for documentation

From pull request qgis/QGIS#44037
Author: @vcloarec
QGIS version: 3.22

** [mesh] mesh frame editing part 3 - Edit mesh map tool**

PR Description:

UPDATED 2021/08/17

This is the beginning of the implementation of the mesh edit map tool. For now this map tool allow:

Add vertices

  • double clicks on a face : add a vertex in the face, remove the face and replace it by triangles from the surrounding vertices to the new vertex
  • double clicks outside a face: add a "free vertex", that is a vertex not link to any face. This vertex is represented by a red dot when the layer is in editing mode

The Z value of the new vertex is taken from the Z value widget on the top right of the canvas.
If some vertices are selected, the value in the Z value widget is the average value of selected vertices.
Deselecting the vertices allows returning to the default value.

If the user adds a vertex with selected vertices (with the average value in the widget), the new vertex will have this average value for Z.
Keeping pressed the Control key allows maintaining this average value for following new vertices, and this value becomes the new default value.

If there is no selected vertex, the Z value for new vertices is the default one in the Z value widget, or if the new vertex is added to face, the Z value is the interpolated value in the face.

If the vertex is snap on a vector layer and the match point is valid, the Z value will be one of the vector layers.

mapTool_add_vertex

Add faces

  • Left click on the little triangle that appears when the mouse is on a boundary vertex or a free vertex start adding a face.
  • The user has to left click on existing vertex to select the vertex of the new face.
  • Double clicks when digitizing a face add a vertices under the mouse and add it to the face.
  • Backspace remove the last selected vertex from the face.
  • If the area of the rubber band is green, right click valid the face and add it to the mesh. If red, the current face is not valid and can't be added.

Snapping on vector layer is supported.

mapTool_add_faces

Select vertices/faces

  • click on a vertex: select one vertex
  • click on the red box in the face centroid: select all the vertices of a face
  • select vertices by dragging rectangle:
    - Default: select all the partially/touched contained faces
    - Alt modifier: select all the completely contained faces

modifier shift: add new selection to the previous selection
modifier ctrl: remove new selection from the previous selection

mapTool_select vertex

Remove vertices/faces

With a selection of vertices (one or many):
"Ctrl"+"Delete" keys: remove vertices and linked faces and fill hole(s) by a triangulation
"Ctrl"+"Shift"+"Delete" keys: remove vertices and linked faces and do NOT fill hole(s)
"Shift"+"Delete" keys: remove faces without vertices
also available with context menu after right click

removeVertices

Change the Z values of vertices

  • select one or many vertices
  • change the value in the Z value widget,
  • press "Enter" key

mapTool_apply_zvalue

Move vertices

Once some vertices/faces are selected:

  • Press left mouse button on selected vertex, or on the red box in middle of selected faces or edges (faces or edges are selected if all their vertices are selected)
  • hold the button press and drag the mouse cursor
  • release when he moved elements are in a desired position
    The rubber band stays green while the faces are valid, and becomes red if some face are invalid or new position of faces leads to intersect other faces or vertices. If the rubber band is red, elements are not moved if the user release the left mouse button.

mapTool_move_vertices

Interaction with edges

When the mouse hover an edge, the edge is highlight and, depending of the configuration of the edge, some markers appears:

  • a box, clicking on it leads to select extremity vertices.
  • a cross if the two faces on either side can be merged, clicking on it leads to merge the faces.
  • a circle if the edge can be flip, clicking on it leads to flip the edge

mapTool_flip_merge

Split faces

When faces are selected:

  • right click, if there are one or more quad faces, the context menu has a command "Split faces"

mapTool_split

Commits tagged with [need-docs] or [FEATURE]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3.22 QGIS 3.22 new features Editing Mesh
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants