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

Some fixes in measure 3d #60849

Open
wants to merge 5 commits into
base: master
Choose a base branch
from
Open

Some fixes in measure 3d #60849

wants to merge 5 commits into from

Conversation

uclaros
Copy link
Contributor

@uclaros uclaros commented Mar 4, 2025

Description

  • Properly update the rubber band when undoing
  • Disable undoing after finishing
  • Fix tracked point being 180 degrees off from mouse cursor
  • Fix last marker being visible after restarting

@uclaros uclaros added 3D Relates to QGIS' 3D engine or rendering Bug Either a bug report, or a bug fix. Let's hope for the latter! labels Mar 4, 2025
@github-actions github-actions bot added this to the 3.44.0 milestone Mar 4, 2025
Copy link

github-actions bot commented Mar 4, 2025

🪟 Windows builds

Download Windows builds of this PR for testing.
Debug symbols for this build are available here.
(Built from commit c5b9efe)

🪟 Windows Qt6 builds

Download Windows Qt6 builds of this PR for testing.
(Built from commit c5b9efe)

@uclaros uclaros closed this Mar 7, 2025
@uclaros uclaros reopened this Mar 7, 2025
@@ -140,6 +140,32 @@ void QgsRubberBand3D::setupPolygon( Qt3DCore::QEntity *parentEntity )
mPolygonEntity->addComponent( mPolygonMaterial );
}

void QgsRubberBand3D::removePoint( int index )
{
if ( QgsPolygon *polygon = qgsgeometry_cast<QgsPolygon *>( mGeometry.constGet() ) )
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You're abusing API here. You're using constGet(), but then modifying the geometry! 😱

Bit this points out a bad issue -- you shouldn't be allowed to qgsgeometry_cast a const geometry pointer to a non-const one. PR incoming...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3D Relates to QGIS' 3D engine or rendering Bug Either a bug report, or a bug fix. Let's hope for the latter!
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants