File tree Expand file tree Collapse file tree 2 files changed +5
-4
lines changed
Expand file tree Collapse file tree 2 files changed +5
-4
lines changed Original file line number Diff line number Diff line change 167167 (ctx => {
168168 let transform = ctx . transform
169169 let perspective-mode = type (projection-matrix ) == function
170+ let previous-perspective-mode = ctx . at (" _perspective-projection" , default : false )
170171 if perspective-mode {
171- ctx . shared-state . insert ( " _perspective-projection" , true )
172+ ctx . _perspective-projection = true
172173 }
173174 ctx . transform = view-matrix
174175
189190
190191 ctx . transform = transform
191192 if perspective-mode {
192- ctx . shared-state . insert ( " _perspective-projection" , false )
193+ ctx . _perspective-projection = previous-perspective-mode
193194 }
194195 if not reset-transform {
195196 drawables = drawable . apply-transform (ctx . transform , drawables )
317318// / Coordinates are transformed by a view matrix and then projected with
318319// / perspective division:
319320// / $x' = (d_"ref" * x) / w$ and $y' = (d_"ref" * y) / w$,
320- // / where $w = max(-z, near)$ in view space.
321+ // / where $w = max(-z, " near" )$ in view space.
321322// /
322323// / By default this uses the same isometric camera angles as `ortho`, but with
323324// / perspective foreshortening.
Original file line number Diff line number Diff line change 358358 let distance = (0 , 0 )
359359 let snap-to = (none , none )
360360 let drawables = ()
361- let perspective-mode = ctx . shared-state . at (" _perspective-projection" , default : false )
361+ let perspective-mode = ctx . at (" _perspective-projection" , default : false )
362362
363363 if style == none {
364364 style = (start : none , end : none , symbol : none )
You can’t perform that action at this time.
0 commit comments