mirror of
https://github.com/processing/processing4.git
synced 2026-06-16 04:26:26 +02:00
much improved bagelpublic, minor fix in editor, applet updated for new bagel
This commit is contained in:
@@ -287,11 +287,12 @@ public class PdeEditor extends Panel implements PdeEnvironment {
|
||||
|
||||
lastDirectory = directory;
|
||||
lastFile = filename;
|
||||
message("Done saving file.");
|
||||
message("Done saving " + filename + ".");
|
||||
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
message("Did not write file.");
|
||||
//message("Did not write file.");
|
||||
message("Could not write " + filename + ".");
|
||||
}
|
||||
buttons.clear();
|
||||
}
|
||||
|
||||
@@ -664,24 +664,18 @@ public class ProcessingApplet extends Applet
|
||||
}
|
||||
|
||||
|
||||
public void ellipse(float x, float y, float hradius, float vradius) {
|
||||
g.ellipse(x, y, hradius, vradius);
|
||||
}
|
||||
|
||||
|
||||
public void cube(float size) {
|
||||
g.cube(size);
|
||||
}
|
||||
|
||||
|
||||
public void box(float x1, float y1, float z1,
|
||||
float x2, float y2, float z2) {
|
||||
g.box(x1, y1, z1, x2, y2, z2);
|
||||
}
|
||||
|
||||
|
||||
public void circle(float x, float y, float radius) {
|
||||
g.circle(x, y, radius);
|
||||
}
|
||||
|
||||
|
||||
public void oval(float x, float y, float hradius, float vradius) {
|
||||
g.oval(x, y, hradius, vradius);
|
||||
public void box(float w, float h, float d) {
|
||||
g.box(w, h, d);
|
||||
}
|
||||
|
||||
|
||||
@@ -695,6 +689,11 @@ public class ProcessingApplet extends Applet
|
||||
}
|
||||
|
||||
|
||||
public Image loadImage(String filename) {
|
||||
return g.loadImage(filename);
|
||||
}
|
||||
|
||||
|
||||
public void image(BagelImage image, float x1, float y1) {
|
||||
g.image(image, x1, y1);
|
||||
}
|
||||
@@ -713,23 +712,23 @@ public class ProcessingApplet extends Applet
|
||||
}
|
||||
|
||||
|
||||
public void loadFont(String s) {
|
||||
g.loadFont(s);
|
||||
public int loadFont(String name) {
|
||||
return g.loadFont(name);
|
||||
}
|
||||
|
||||
|
||||
public void setFont(String s) {
|
||||
g.setFont(s);
|
||||
public void setFont(int which) {
|
||||
g.setFont(which);
|
||||
}
|
||||
|
||||
|
||||
public void text(char c) {
|
||||
g.text(c);
|
||||
public void text(char c, float x, float y) {
|
||||
g.text(c, x, y);
|
||||
}
|
||||
|
||||
|
||||
public void text(String s) {
|
||||
g.text(s);
|
||||
public void text(String s, float x, float y) {
|
||||
g.text(s, x, y);
|
||||
}
|
||||
|
||||
|
||||
@@ -938,4 +937,9 @@ public class ProcessingApplet extends Applet
|
||||
public void message(int level, String message, Exception e) {
|
||||
g.message(level, message, e);
|
||||
}
|
||||
|
||||
|
||||
public InputStream getStream(String filename) throws IOException {
|
||||
return g.getStream(filename);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -34,9 +34,14 @@ while ($line = shift(@contents)) {
|
||||
}
|
||||
next if ($comments > 0);
|
||||
|
||||
if ($line =~ /^\s*(public \w+ [a-zA-z_]+\(.*$)/) {
|
||||
if ($line =~ /^\s*public (\w+) [a-zA-z_]+\(.*$/) {
|
||||
#print "$1\n";
|
||||
#$decl .= $line;
|
||||
if ($1 ne 'void') {
|
||||
$returns = 'return';
|
||||
} else {
|
||||
$returns = '';
|
||||
}
|
||||
print "\n\n$line";
|
||||
$decl .= $line;
|
||||
while (!($line =~ /\)/)) {
|
||||
@@ -49,7 +54,7 @@ while ($line = shift(@contents)) {
|
||||
$decl =~ /\s(\S+)\(/;
|
||||
$decl_name = $1;
|
||||
#print "dec $decl_name\n";
|
||||
print " g.${decl_name}(";
|
||||
print " $returns g.${decl_name}(";
|
||||
|
||||
$decl =~ s/\s+/ /g; # smush onto a single line
|
||||
$decl =~ s/^.*\(//;
|
||||
|
||||
+18
-9
@@ -66,6 +66,7 @@ _ using them in your app will break things (i.e. init())
|
||||
|
||||
|
||||
PROCESSING - MEDIUM
|
||||
_ comprehensive list of reserved keywords
|
||||
_ better handling on portinuse exception
|
||||
_ or general exception handling--could go through some interface
|
||||
_ compile from the sketchbook if there are changes
|
||||
@@ -108,13 +109,16 @@ _ how to use ssh identity file to maintain auth for brancusi
|
||||
|
||||
BAGEL
|
||||
X got rid of colorscale and using colormode for all instead
|
||||
_ make changes in documentation
|
||||
X 'ellipse' instead of 'oval'?
|
||||
_ make note in documentation
|
||||
_ catmullrom is broken
|
||||
X catmullrom is broken
|
||||
_ write documentation for new curve functions
|
||||
|
||||
_ get web documentation back into cvs
|
||||
_ have to get rid of static i/o stuff before porting to c
|
||||
|
||||
_ may also need to get rid of floating point constants
|
||||
_ current acu fonts are broken
|
||||
|
||||
_ 'ellipse' instead of 'oval'?
|
||||
_ area copying function: copy(x1, y1, w, h, xto, yto);
|
||||
|
||||
_ should math functions be moved in?
|
||||
@@ -132,9 +136,11 @@ _ or x, y, diameter
|
||||
_ make note in docs about removal of LINE from LINES
|
||||
_ build in second matrix type: 2d affine
|
||||
_ add convex polygon type
|
||||
_ make note in documentation about convex polygons
|
||||
_ make note in documentation about convex polygons
|
||||
|
||||
_ sketch in antialiasing functions
|
||||
_ how does color depth work on ipaq? 4-4-4? 5-6-5?
|
||||
|
||||
_ font usage/substition solution
|
||||
_ java freetype? jni freetype to build texmap fonts?
|
||||
_ look at flash file format? (does it have kerning?)
|
||||
@@ -143,22 +149,25 @@ _ screen grabbing code
|
||||
_ simpler bitmap fonts w/o smoothing, just 2D
|
||||
_ alpha blending (easier)
|
||||
_ antialiasing
|
||||
_ bresenham (flat) oval function
|
||||
_ setting origins
|
||||
_ should shapes draw from center or from upper left?
|
||||
_ should ovals use radius or diameter?
|
||||
_ should shapes use x1, y1 - x2, y2 or x, y, w, h?
|
||||
|
||||
BAGEL - SHOULD DO
|
||||
|
||||
BAGEL - SHOULD
|
||||
_ bresenham (flat) oval function
|
||||
_ setting accuracy of circles/sphere
|
||||
_ setting accuracy of curve segments
|
||||
_ write shearing function
|
||||
_ optimize rotation functions
|
||||
_ test winding polygons in different directions
|
||||
_ test lighting to see how it compares with gl
|
||||
|
||||
BAGEL - FEATURES
|
||||
_ non-homogenous colors for beginShape()
|
||||
_ currently disabled b/c homogenousColors not set false for vertices
|
||||
_ and code not written for curve vertices
|
||||
_ better lockout inside beginShape() to keep other things from happening
|
||||
_ when stroke in use, stroke letters (currently stroke doesn't affect
|
||||
|
||||
|
||||
BUG WATCH
|
||||
|
||||
Reference in New Issue
Block a user