Skip to content

Commit

Permalink
Merge branch 'feature/perspectiveMatrix'
Browse files Browse the repository at this point in the history
  • Loading branch information
Koen Bok committed Jan 12, 2016
2 parents d4c15a4 + df3e145 commit c65dff5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions framer/Utils.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -752,10 +752,10 @@ Utils.pointAngle = (p1, p2) ->
# Coordinate system

# convert a point from a layer to the context level, with limit you can make it continue to the root context
Utils.convertPointToContext = (point = {}, layer, limit=false) ->
Utils.convertPointToContext = (point = {}, layer, limit=false, includeLayer = true) ->
point = _.defaults(point, {x:0, y:0, z:0})
ancestors = layer.ancestors(limit)
ancestors.unshift(layer)
ancestors.unshift(layer) if includeLayer

for ancestor in ancestors
point.z = 0 if ancestor.flat
Expand Down

0 comments on commit c65dff5

Please sign in to comment.