Flash Player 10 (CS4 または最新の flex SDK が必要) 用にコンパイルしている場合は、テキスト フィールドを 3D で回転させることができます。
text.rotateX = -45;
これには、フォントの埋め込みを使用する必要があり、フィールドの中心に消失点を取得する必要があるなど、さらにいくつかの問題があります。
マゾヒスティックで、垂直方向のエイリアシングを気にしない場合は、10 未満の Flash Player でビットマップを使用してこれを行うことも可能です。アイデアは、BitmapData.draw() を使用して、高さ 1 のクリッピング rect と変換を使用して各線を描画し、遠近法による分割を行うことです。例 (フレックス):
class Main extends Sprite
{
[Embed(systemFont="Arial", fontName="embedFont", mimeType="application/x-font")]
var embedFont:Class;
public function Main()
{
var text:TextField = new TextField();
text.defaultTextFormat = new TextFormat("embedFont", 30);
text.embedFonts = true;
text.autoSize = TextFieldAutoSize.LEFT;
text.text = "Hello, world\nHow nice\nto have\nmultiple\nlines!";
var bmp:BitmapData = new BitmapData(150, 100);
for (var i:int = 0; i != bmp.height; ++i) {
var m:Matrix = new Matrix();
// x-division, change 0.8, 0.2 to change scale increase, scale at top
m.a = i*(0.8/bmp.height)+0.2;
// horizontal center
m.tx = bmp.width * (1-m.a) / 2;
// y-division, and align text to bottom
m.ty = (bmp.height-i)/m.a - bmp.height;
bmp.draw(text, m, null, null, new Rectangle(0, i, bmp.width, 1));
}
addChild(new Bitmap(bmp));
}
}
私は計算をしていないので、物理的に正確かどうかはわかりませんが、アイデアが得られるはずです。