Skip to content

Commit

Permalink
Implement various fixes post visual classes overhaul.
Browse files Browse the repository at this point in the history
  • Loading branch information
KelSolaar committed Oct 29, 2023
1 parent 34b6b8e commit 0d8be2a
Show file tree
Hide file tree
Showing 11 changed files with 12 additions and 2 deletions.
4 changes: 2 additions & 2 deletions colour_visuals/diagrams.py
Original file line number Diff line number Diff line change
Expand Up @@ -489,13 +489,13 @@ def update(self):
[-1, 3]
)
else:
colours = np.tile(self._colour, (positions.shape[0], 1))
colour = np.tile(self._colour, (positions.shape[0], 1))

self._spectral_locus = gfx.Line(
gfx.Geometry(
positions=as_contiguous_array(positions),
colors=as_contiguous_array(
append_channel(colours, self._opacity)
append_channel(colour, self._opacity)
),
),
gfx.LineSegmentMaterial(
Expand Down
5 changes: 5 additions & 0 deletions colour_visuals/rgb_scatter.py
Original file line number Diff line number Diff line change
Expand Up @@ -190,6 +190,11 @@ def RGB(self, value: ArrayLike):
def update(self):
"""Update the visual."""

if self._is_update_blocked:
return

self.clear()

XYZ = RGB_to_XYZ(self._RGB, self._colourspace)

positions = colourspace_model_axis_reorder(
Expand Down
5 changes: 5 additions & 0 deletions colour_visuals/rosch_macadam.py
Original file line number Diff line number Diff line change
Expand Up @@ -173,6 +173,11 @@ def __init__(
def update(self):
"""Update the visual."""

if self._is_update_blocked:
return

self.clear()

colourspace = CONSTANTS_COLOUR_STYLE.colour.colourspace

XYZ = XYZ_outer_surface(
Expand Down
Binary file modified docs/_static/Plotting_VisualAxes.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/_static/Plotting_VisualChromaticityDiagramCIE1931.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/_static/Plotting_VisualChromaticityDiagramCIE1960UCS.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/_static/Plotting_VisualChromaticityDiagramCIE1976UCS.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/_static/Plotting_VisualSpectralLocus2D.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/_static/Visuals_001.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/_static/Visuals_002.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/_static/Visuals_003.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 0d8be2a

Please sign in to comment.