Skip to content

Commit

Permalink
Fix anaglyph ordering
Browse files Browse the repository at this point in the history
  • Loading branch information
scottshambaugh committed Dec 24, 2023
1 parent c554c8d commit 823d121
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 3 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
- GH release publish to pypi
- zlim handling and consistent depth
- AxesAnaglyph.imshow_stereo() other colormaps
- AxesAnaglyph.imshow_stereo() full color images

----

Expand All @@ -17,6 +18,10 @@
### Changed
### Removed

## [0.4.1] - 2023-12-24
### Changed
* Fix anaglyph color ordering

## [0.4.0] - 2023-12-23
### Added
* `AxesAnaglyph.imshow_stereo()` for generating anaglyphs from existing image data
Expand Down
Binary file modified docs/sun_anaglyph.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "mpl_stereo"
version = "0.4.0"
version = "0.4.1"
description = "See your matplotlib plots in 3D by making stereograms and anaglyphs"
authors = ["Scott Shambaugh <[email protected]>"]
license = "MIT"
Expand Down
4 changes: 2 additions & 2 deletions src/mpl_stereo/AxesStereo.py
Original file line number Diff line number Diff line change
Expand Up @@ -620,8 +620,8 @@ def imshow_stereo(self, data_left: np.ndarray, data_right: np.ndarray, *args, **
The data from the right image.
"""
named_colors = mpl.colors.get_named_colors_mapping()
color_tuple_left = mpl.colors.hex2color(named_colors[self.colors[0]])
color_tuple_right = mpl.colors.hex2color(named_colors[self.colors[1]])
color_tuple_left = mpl.colors.hex2color(named_colors[self.colors[1]])
color_tuple_right = mpl.colors.hex2color(named_colors[self.colors[0]])

cmap_left = copy.deepcopy(plt.get_cmap('gray'))
cmap_right = copy.deepcopy(cmap_left)
Expand Down

0 comments on commit 823d121

Please sign in to comment.