point2.java
来自「Sunflow是一个照片级的渲染系统」· Java 代码 · 共 35 行
JAVA
35 行
package org.sunflow.math;
public final class Point2 {
public float x, y;
public Point2() {
}
public Point2(float x, float y) {
this.x = x;
this.y = y;
}
public Point2(Point2 p) {
x = p.x;
y = p.y;
}
public final Point2 set(float x, float y) {
this.x = x;
this.y = y;
return this;
}
public final Point2 set(Point2 p) {
x = p.x;
y = p.y;
return this;
}
@Override
public final String toString() {
return String.format("(%.2f, %.2f)", x, y);
}
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?