glue-viz / glue-plotly

Experimental plot.ly plugin for glue
BSD 3-Clause "New" or "Revised" License
2 stars 8 forks source link

Set exported camera projection based on glue viewer state. #13

Closed Carifio24 closed 2 years ago

Carifio24 commented 2 years ago

This PR sets the projection of the camera used in the exported file based on the perspective_view property of the glue layer state. If perspective_view is true, "perspective" is used, while "orthographic" is used if it's false. Note that these are the only two options supported in plotly (relevant documentation is here).

I'm happy to add tests using both options if we think it's necessary.

codecov[bot] commented 2 years ago

Codecov Report

Merging #13 (ef4404e) into main (c1c1c65) will increase coverage by 0.03%. The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main      #13      +/-   ##
==========================================
+ Coverage   85.75%   85.78%   +0.03%     
==========================================
  Files           8        8              
  Lines         400      401       +1     
==========================================
+ Hits          343      344       +1     
  Misses         57       57              
Impacted Files Coverage Δ
glue_plotly/html_exporters/scatter3d.py 76.66% <100.00%> (+0.26%) :arrow_up:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update c1c1c65...ef4404e. Read the comment docs.