本文整理汇总了Java中com.esotericsoftware.kryo.io.Input.readFloat方法的典型用法代码示例。如果您正苦于以下问题:Java Input.readFloat方法的具体用法?Java Input.readFloat怎么用?Java Input.readFloat使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类com.esotericsoftware.kryo.io.Input
的用法示例。
在下文中一共展示了Input.readFloat方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: read
import com.esotericsoftware.kryo.io.Input; //导入方法依赖的package包/类
@Override
public PerspectiveCamera read (Kryo kryo, Input input, Class<PerspectiveCamera> type) {
PerspectiveCamera camera = new PerspectiveCamera();
Vector3 position = kryo.readObject(input, Vector3.class);
Vector3 direction = kryo.readObject(input, Vector3.class);
Vector3 up = kryo.readObject(input, Vector3.class);
camera.position.set(position);
camera.direction.set(direction);
camera.up.set(up);
camera.near = input.readFloat();
camera.far = input.readFloat();
camera.viewportWidth = input.readFloat();
camera.viewportHeight = input.readFloat();
camera.fieldOfView = input.readFloat();
camera.update();
return camera;
}
示例2: read
import com.esotericsoftware.kryo.io.Input; //导入方法依赖的package包/类
@Override
public OrthographicCamera read(Kryo kryo, Input input, Class<OrthographicCamera> type) {
OrthographicCamera camera = new OrthographicCamera();
Vector3 position = kryo.readObject(input, Vector3.class);
Vector3 direction = kryo.readObject(input, Vector3.class);
Vector3 up = kryo.readObject(input, Vector3.class);
camera.position.set(position);
camera.direction.set(direction);
camera.up.set(up);
camera.near = input.readFloat();
camera.far = input.readFloat();
camera.viewportWidth = input.readFloat();
camera.viewportHeight = input.readFloat();
camera.zoom = input.readFloat();
camera.update();
return camera;
}
示例3: read
import com.esotericsoftware.kryo.io.Input; //导入方法依赖的package包/类
public ArrayMetaData<float[]> read(Kryo kryo, Input input, Class<ArrayMetaData<float[]>> type) {
try {
float[] arrData = arrayMetaData.getArrData();
thatArrMetaData = arrayMetaData.recv(input);
int arrSegNum = thatArrMetaData.getSegNum();
for (int i = 0; i < arrSegNum; i++) {
int from = thatArrMetaData.getFrom(i);
int to = thatArrMetaData.getTo(i);
for (int j = from; j < to; j++) {
arrData[j] = input.readFloat();
}
}
thatArrMetaData.setArrData(arrData);
} catch (IOException e) {
LOG.error("double array read exception", e);
System.exit(1);
}
return thatArrMetaData;
}
示例4: read
import com.esotericsoftware.kryo.io.Input; //导入方法依赖的package包/类
@Override
public BoundingBox read(Kryo kryo, Input input, Class<BoundingBox> type) {
Vector3 min = new Vector3();
min.x = input.readFloat();
min.y = input.readFloat();
min.z = input.readFloat();
Vector3 max = new Vector3();
max.x = input.readFloat();
max.y = input.readFloat();
max.z = input.readFloat();
return new BoundingBox(min, max);
}
示例5: read
import com.esotericsoftware.kryo.io.Input; //导入方法依赖的package包/类
@Override
public Sphere read(Kryo kryo, Input input, Class<Sphere> type) {
Vector3 center = new Vector3();
center.x = input.readFloat();
center.y = input.readFloat();
center.z = input.readFloat();
float radius = input.readFloat();
return new Sphere(center, radius);
}
示例6: read
import com.esotericsoftware.kryo.io.Input; //导入方法依赖的package包/类
@Override
public Ray read(Kryo kryo, Input input, Class<Ray> type) {
Ray ray = new Ray();
Vector3 origin = ray.origin;
origin.x = input.readFloat();
origin.y = input.readFloat();
origin.z = input.readFloat();
Vector3 direction = ray.direction;
direction.x = input.readFloat();
direction.y = input.readFloat();
direction.z = input.readFloat();
return ray;
}
示例7: read
import com.esotericsoftware.kryo.io.Input; //导入方法依赖的package包/类
@Override
public Segment read(Kryo kryo, Input input, Class<Segment> type) {
Vector3 a = new Vector3();
a.x = input.readFloat();
a.y = input.readFloat();
a.z = input.readFloat();
Vector3 b = new Vector3();
b.x = input.readFloat();
b.y = input.readFloat();
b.z = input.readFloat();
return new Segment(a, b);
}
示例8: read
import com.esotericsoftware.kryo.io.Input; //导入方法依赖的package包/类
@Override
public Quaternion read(Kryo kryo, Input input, Class<Quaternion> type) {
float x = input.readFloat();
float y = input.readFloat();
float z = input.readFloat();
float w = input.readFloat();
return new Quaternion(x, y, z, w);
}
示例9: read
import com.esotericsoftware.kryo.io.Input; //导入方法依赖的package包/类
@Override
public Vector3 read(Kryo kryo, Input input, Class<Vector3> type) {
float x = input.readFloat();
float y = input.readFloat();
float z = input.readFloat();
return new Vector3(x, y, z);
}
示例10: read
import com.esotericsoftware.kryo.io.Input; //导入方法依赖的package包/类
@Override
public Circle read(Kryo kryo, Input input, Class<Circle> type) {
float x = input.readFloat();
float y = input.readFloat();
float radius = input.readFloat();
return new Circle(x, y, radius);
}
示例11: read
import com.esotericsoftware.kryo.io.Input; //导入方法依赖的package包/类
@Override
public Ellipse read(Kryo kryo, Input input, Class<Ellipse> type) {
float x = input.readFloat();
float y = input.readFloat();
float width = input.readFloat();
float height = input.readFloat();
return new Ellipse(x, y, width, height);
}
示例12: read
import com.esotericsoftware.kryo.io.Input; //导入方法依赖的package包/类
@Override
public Plane read(Kryo kryo, Input input, Class<Plane> type) {
Plane plane = new Plane();
Vector3 normal = plane.normal;
normal.x = input.readFloat();
normal.y = input.readFloat();
normal.z = input.readFloat();
plane.d = input.readFloat();
return plane;
}
示例13: read
import com.esotericsoftware.kryo.io.Input; //导入方法依赖的package包/类
@Override
public SplitInfo read(Kryo kryo, Input input, Class<SplitInfo> type) {
SplitInfo splitInfo = new SplitInfo();
splitInfo.lossChg = input.readFloat();
splitInfo.splitIndex = input.readInt();
splitInfo.splitValue = input.readFloat();
int len = input.readInt();
splitInfo.splitSlotInterval = new int[len];
for (int i = 0; i < len; i++) {
splitInfo.splitSlotInterval[i] = input.readInt();
}
return splitInfo;
}
示例14: read
import com.esotericsoftware.kryo.io.Input; //导入方法依赖的package包/类
@Override
public Affine2 read(Kryo kryo, Input input, Class<Affine2> type) {
Affine2 affine2 = new Affine2();
affine2.m00 = input.readFloat();
affine2.m01 = input.readFloat();
affine2.m02 = input.readFloat();
affine2.m10 = input.readFloat();
affine2.m11 = input.readFloat();
affine2.m12 = input.readFloat();
return affine2;
}
示例15: read
import com.esotericsoftware.kryo.io.Input; //导入方法依赖的package包/类
@Override
public Summary read(Kryo kryo, Input input, Class<Summary> type) {
Summary summary = new Summary();
int len = input.readInt();
summary.value = new float[len];
for (int i = 0; i < len; i++) {
summary.value[i] = input.readFloat();
}
len = input.readInt();
summary.rmin = new double[len];
for (int i = 0; i < len; i++) {
summary.rmin[i] = input.readDouble();
}
len = input.readInt();
summary.rmax = new double[len];
for (int i = 0; i < len; i++) {
summary.rmax[i] = input.readDouble();
}
len = input.readInt();
summary.w = new float[len];
for (int i = 0; i < len; i++) {
summary.w[i] = input.readFloat();
}
summary.capacity = input.readInt();
summary.cursor = input.readInt();
summary.B = input.readDouble();
summary.exact = input.readBoolean();
summary.eps = input.readDouble();
summary.poolMap = new TreeMap<>();
PoolNode poolNode = summary.getPoolNode(summary.capacity);
return summary;
}