Rotate Text Help!
|
10-31-2016, 05:33 PM
Post: #2
|
|||
|
|||
RE: Rotate Text Help!
To rotate something, simplest way is to use a translation matrix (i.e. with xyz vectors). Of course you can use a simpler form if you don't consider the axis of the rotation (make it 0) and remove z:
Code: local mat:=[[cos(angle),sin(angle)],[-sin(angle),cos(angle)]]; The new position of every rotated pixel will be equal to: Code: newpos:=mat*[[sourceX],[sourceY]]; Working code: Code: RotateG(source,destination,angle) Of course this code is not very efficient, you may crop the source to size, add the "axis" for the rotation, etc... My website: erwin.ried.cl |
|||
« Next Oldest | Next Newest »
|
Messages In This Thread |
Rotate Text Help! - Spybot - 10-31-2016, 05:50 AM
RE: Rotate Text Help! - eried - 10-31-2016 05:33 PM
RE: Rotate Text Help! - Spybot - 11-01-2016, 06:43 AM
RE: Rotate Text Help! - Chasfield - 11-02-2016, 04:12 PM
|
User(s) browsing this thread: 1 Guest(s)