インフォ | FAQ |
言語 | 環境 | 比較 |
Index |
Java | ActionScript
| Lingo |
Python | Design
By Numbers
ActionScriptの描写のためのコードは高度に最適化されている。そして、シェープはProcessingよりも速くスクリーンに描かれる。これはFlashアプリケーションのピクセル容量をを大きくさせ、透明やアンチエイリアスグラフィックスを大量に使うことができる。 計算 ActionScriptは計算するのがとても遅い。それ故に、Processingは多くのエレメントを持つアプリケーションに優れている。 ピクセル 操作 ActionScriptはベクター描写のために開発されたために、ピクセルを直接に操作することを無視している。Processingはイメージのピクセルに単純にアクセスできる機能やデータ構造を提供しており、多くのおもしろいプログラムを書くための可能性を造り出す。 3D ActionScriptは3次元で内部的に空間的構造を表現しない。一方、Processingの描写ライブラリーは本質的に3次元である。 オブジェクト ActionScript は本質的にオブジェクト指向である。一方、Processingでは手続き、オブジェクト指向の両方の方法で書くことができる。Processingで学んでいる学生は、はじめにオブジェクト指向を理解する前にプログラムの基本を理解させることができる。
|
Processing | ActionScript | |
background(0); background(255); |
N/A | |
background(255, 204, 0); | N/A | |
stroke(255); stroke(0); |
lineStyle(x,0xFFFFFF,a) lineStyle(x,0x000000,a) |
|
stroke(255, 204, 0); | lineStyle(x,0xFFCC00,a) | |
fill(0, 102, 153); | beginFill (0x006699, alpha); beginGradientFill(filltype, colors[], alphas, ratios, matrix); |
|
Processing | ActionScript | |
point(30, 20); | moveTo(x1,y1); lineTo(x1,y1); |
|
line(0, 20, 80, 20); | moveTo(x1,y1); lineTo(x2,y2); |
|
rect(10, 20, 30, 30); | moveTo(10,20); lineTo(30,20); lineTo(30,30); lineTo(10,30); |
|
Processing | ActionScript | |
setPixel(30, 20, 255); | N/A | |
a = getPixel(60, 10); | N/A | |
pixels[y*width+x] | N/A | |
Processing | ActionScript | |
int x = 70; //
Initialize x = 30; // Change value |
var x = 70; // Initialize
x = 30; // Change value |
|
float x = 70.0; x = 30.0; |
var x = 70.0; x = 30.0; |
|
int[] a = {5, 10, 11}; a[0] = 12; // Reassign |
a = new Array{5,10,11}; a[0] = 12; // Reassign |
|
Processing | ActionScript | |
void loop() { // Statements } |
do { // Statements } |
|
for(int a=45; a<=55; a++) { // Statements } |
for(a=45; a<=55; a++) { // Statements } |
|
if(c==1) { // Statements } |
if(c==1) { // Statements } |
|
if(c!=1) { // Statements } |
if(c!=1) { // Statements } |
|
if(c < 1) { // Statements } |
if(c < 1) { // Statements } |
|
if(c >= 1) { // Statements } |
if c >= 1: # Statements |
|
if((c >= 1) && (c < 20)) { // Statements } |
if((c >= 1) && (c < 20)) { // Statements } |
|
if(c >= 20) { |
if(c >= 20) { // Statements 1 } else if (c == 0) { // Statements 2 } else { // Statements 3 } |
|
Processing | ActionScript | |
// Comment | // Comment | |
void doIt(int x) { // Statements } doIt(x); |
function doIt(int x) { // Statements } doIt(x); |
|
int square(int x) { return x*x; } square(X); |
function square(int x) { return x*x; } square(x); |
|
Processing | ActionScript | |
mouseX mouseY mousePressed |
_Xmouse _Ymouse N/A |
|
void mousePressed() { // Statements } |
mice = new Object(); mice.onMouseDown = function() { // Statements } |
|
(key=='a') (key=='b') ... |
(chr(key.getAscii()) == 'a') (chr(key.getAscii()) == 'b') ... |
|
void keyPressed() { // Statements } |
key = new Object(); key.onKeyDown = function() { // Statements } |
|
hour() minute() second() |
now = new Date(); now.getHours() now.getMinutes() now.getSeconds() |
|
Processing >> ActionScript by JimQode, Martin, XemonerdX, Dara |
© 2004- 2001 Massachusetts Institute of Technology and Interaction Design Institute Ivrea | ||
Processing is an open project initiated by Ben Fry and Casey Reas |