Skip to content

Instantly share code, notes, and snippets.

@animoplex
Created April 16, 2018 16:02
Embed
What would you like to do?
JavaScript Math Methods - After Effects Expression by Animoplex
// JavaScript Math Methods - Created by Animoplex: www.animoplex.com
// List of math methods for After Effects expressions and what they output.
// Note: You must capitalize the M in Math for these methods to work properly.
Math.abs(-2) // Returns 2
Math.ceil(1.01) // Returns 2
Math.floor(1.99) // Returns 1
Math.min(1, 2, 3) // Returns 1
Math.max(1, 2, 3) // Returns 3
Math.round(1.49) // Returns 1
Math.PI // Returns 3.141592 and so on, useful for circles
Math.sin() // Trigonometry function
Math.cos() // Trigonometry function
Math.tan() // Trigonometry function
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment