Jump to content
GreenSock

Search In
  • More options...
Find results that contain...
Find results in...
RABBIT DIGITAL

Skew an element without animating

Recommended Posts

Can some one help me get started with Skewing an element without animating it

 

I have tried using

 

TweenLite.fromTo([skew], 1, {scaleX:0, scaleY:0.8}, {scakeX:0, scaleY:0.8})

 

But it disappears from the screen, I want to skew an element & fix it on the screen

Refer attached image

 

Thanks

Dexter

post-13317-0-71994200-1356951394_thumb.jpg

Link to comment
Share on other sites

Okay, a few things:

  1. You set the scaleX to 0 which means it'll literally have no width whatsoever - that's why it "disappeared".
  2. You misspelled scaleX as scakeX in the "to" vars.
  3. Are you trying to skew something in Flash or Javascript? You posted in the TransformManager forum which is technically ActionScript, but your question has nothing to do with TransformManager so I'm not sure if it was a mistake. In ActionScript, DisplayObjects don't have a skewX or skewY property but you can use the transformMatrix plugin to get that kind of functionality. See the interactive example in the plugin explorer at http://www.greensock.com/tweenlite/#plugins (click the "EXAMPLE" button next to transformMatrix)
  4. The jpg you attached doesn't show a skew effect - it shows a 3D rotation effect. Skewing will always keep the sides (or top and bottom) parallel. I suspect you probably want to just put a bunch of images in a Sprite and then change that container Sprite's rotationY property (no need to use TweenLite if you don't want to animate it).

I hope that helps.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    No registered users viewing this page.

×