georegression.fitting.sphere
Class CodecSphere3D_F32
- java.lang.Object
-
- georegression.fitting.sphere.CodecSphere3D_F32
-
- All Implemented Interfaces:
- ModelCodec<Sphere3D_F32>
public class CodecSphere3D_F32 extends java.lang.Object implements ModelCodec<Sphere3D_F32>
Encodes and decodesSphere3D_F32into float[].sphere.center.x = input[0]; sphere.center.y = input[1]; sphere.center.z = input[2]; sphere.radius = input[3];
-
-
Constructor Summary
Constructors Constructor and Description CodecSphere3D_F32()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description voiddecode(double[] input, Sphere3D_F32 sphere)Converts the parameter array into a model.voidencode(Sphere3D_F32 sphere, double[] param)Converts the provided model into the array format.intgetParamLength()Number of elements in array encoded parameters.
-
-
-
Method Detail
-
decode
public void decode(double[] input, Sphere3D_F32 sphere)Description copied from interface:ModelCodecConverts the parameter array into a model.- Specified by:
decodein interfaceModelCodec<Sphere3D_F32>- Parameters:
input- input model parameters.sphere- Option (can be null) model.
-
encode
public void encode(Sphere3D_F32 sphere, double[] param)
Description copied from interface:ModelCodecConverts the provided model into the array format.- Specified by:
encodein interfaceModelCodec<Sphere3D_F32>- Parameters:
sphere- Input model.param- Output parameterized model. Can be null.
-
getParamLength
public int getParamLength()
Description copied from interface:ModelCodecNumber of elements in array encoded parameters.- Specified by:
getParamLengthin interfaceModelCodec<Sphere3D_F32>
-
-
DataMelt 3.0 © DataMelt by jWork.ORG