Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
ParaView
ParaView
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 1,674
    • Issues 1,674
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
  • Merge Requests 59
    • Merge Requests 59
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Operations
    • Operations
    • Incidents
    • Environments
  • Analytics
    • Analytics
    • CI/CD
    • Repository
    • Value Stream
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Members
    • Members
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • ParaView
  • ParaViewParaView
  • Issues
  • #19807

Closed
Open
Created Mar 30, 2020 by Florian Maurin@florian360Contributor

Switch from Gauss to Mean curvature no working

To reproduce:

  • Source -> Sphere -> Apply
  • Filter-> Curvature -> Apply (the default curvature displayed is Gaussian, and is working fine )
  • Switch the curvature type to Mean, nothing is displayed, and the legend caption remain Gauss_Curvature.

In filters_filtersgeneral.xml we have

      <IntVectorProperty command="SetCurvatureType"
                         default_values="0"
                         name="CurvatureType"
                         number_of_elements="1">
        <EnumerationDomain name="enum">
          <Entry text="Gaussian"
                 value="0" />
          <Entry text="Mean"
                 value="1" />

If we switch default_values="0" to default_values="1", the opposite happen: the Mean curvature is working, but not the Gaussian.

So this is not a problem in the implementation of the Mean curvature.

In vtkCurvatures::GetGaussCurvature(vtkPolyData* output) we have something equivalent to:

gaussCurvature->SetName("Gauss_Curvature");
output->GetPointData()->AddArray(gaussCurvature);
output->GetPointData()->SetActiveScalars(gaussCurvature->GetName());

and in vtkCurvatures::GetMeanCurvature(vtkPolyData* output) we have something equivalent to:

meanCurvature->SetName("Mean_Curvature");
output->GetPointData()->AddArray(meanCurvature);
output->GetPointData()->SetActiveScalars(meanCurvature->GetName());

If both names "Mean_Curvature" and "Gauss_Curvature" are renamed with the same name as for instance "Curvature", things are working fine.

So the problem would be that SetActiveScalars is not working correctly, or that the filter is not loading the active scalar. But I don't know where this happen.

Any thought?

Edited Mar 30, 2020 by Florian Maurin
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
None
Milestone
None
Assign milestone
Time tracking
None
Due date
None