Skip to content

Unify VolumeRGB and VertexRGB signatures (fixes #579)#599

Open
mvdoc wants to merge 6 commits intomainfrom
fix/unify-rgb-signatures-579
Open

Unify VolumeRGB and VertexRGB signatures (fixes #579)#599
mvdoc wants to merge 6 commits intomainfrom
fix/unify-rgb-signatures-579

Conversation

@mvdoc
Copy link
Contributor

@mvdoc mvdoc commented Mar 8, 2026

Summary

  • Move color_voxels static method from VolumeRGB to DataviewRGB base class, generalized for VertexData
  • Add color remapping support to VertexRGB: shared_range, shared_vmin, shared_vmax, custom channel colors (channel1color, channel2color, channel3color), and HSV controls (max_color_value, max_color_saturation)
  • Remove **kwargs from DataviewRGB, VolumeRGB, and VertexRGB __init__ signatures — unsupported keyword arguments now raise TypeError instead of being silently swallowed

Test plan

  • Existing tests pass (43/43, 1 unrelated failure in test_download_subject)
  • New tests for VertexRGB with shared_range
  • New tests for VertexRGB with custom channel colors
  • New tests for TypeError on unknown kwargs (both VolumeRGB and VertexRGB)
  • Regression tests for VolumeRGB shared_range and custom colors

Closes #579

mvdoc added 6 commits March 7, 2026 20:08
…ering

- Remove **kwargs from VolumeRGB docstring (no longer accepted)
- Filter kwargs in _from_hdf_data for old-style RGB volumes to avoid
  passing unsupported params (cmap, vmin, vmax) to RGB constructors
- Fix docstring typo: "vim" -> "vmin" in VolumeRGB
- Fix error message: channel 3 validation said "channel 2"
- Add priority param to VertexRGB docstring
- Consistent kwargs filtering style in _from_hdf_view
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

VolumeRGB and VertexRGB don't have the same signature and functionality (e.g., shared_range, custom colors, etc.)

1 participant