Package com.irurueta.geometry.io
Class MeshWriterBinaryTest
java.lang.Object
com.irurueta.geometry.io.MeshWriterBinaryTest
- All Implemented Interfaces:
MeshWriterListener
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate voidcheckLocked(MeshWriterBinary writer) private booleanprivate booleanprivate booleanprivate booleanvoidonChunkAvailable(MeshWriter writer, DataChunk chunk) voidonDidValidateTexture(MeshWriter writer, File f) onMaterialFileRequested(MeshWriter writer, String path) onTextureDataAvailable(MeshWriter writer, File textureFile, int textureWidth, int textureHeight) voidonTextureDataProcessed(MeshWriter writer, File textureFile, int textureWidth, int textureHeight) onTextureReceived(MeshWriter writer, int textureWidth, int textureHeight) onValidateTexture(MeshWriter writer, Texture texture) voidonWriteEnd(MeshWriter writer) voidonWriteProgressChange(MeshWriter writer, float progress) voidonWriteStart(MeshWriter writer) private void(package private) static void(package private) static void(package private) void(package private) void(package private) void(package private) void(package private) voidtestWriteAndIsReadyObj(String inputFile, String outputFile) (package private) voidtestWriteAndIsReadyPly(String inputFile, String outputFile)
-
Field Details
-
INPUT_FOLDER
- See Also:
-
TMP_FOLDER
- See Also:
-
startValid
private boolean startValid -
endValid
private boolean endValid -
progressValid
private boolean progressValid -
lockedValid
private boolean lockedValid -
startCounter
private int startCounter -
endCounter
private int endCounter -
previousProgress
private float previousProgress
-
-
Constructor Details
-
MeshWriterBinaryTest
MeshWriterBinaryTest()
-
-
Method Details
-
setUpClass
@BeforeAll static void setUpClass() -
tearDownClass
@AfterAll static void tearDownClass() -
testConstructors
- Throws:
IOException
-
testGetSetListener
- Throws:
IOExceptionLockedException
-
testWriteAndIsReadyPly
@ParameterizedTest(name="{index} - inputFile = {0}, outputFile = {1}") @CsvSource({"randomAscii.ply,randomAscii.bin","randomLittle.ply,randomLittle.bin","randomBig.ply,randomBig.bin","booksBinary.ply,booksBinary.bin","booksAscii.ply,booksAscii.bin","pilarAscii.ply,pilarAscii.bin","pilarLittleEndian.ply,pilarLittleEndian.bin","pilarBigEndian.ply,pilarBigEndian.bin"}) void testWriteAndIsReadyPly(String inputFile, String outputFile) throws IOException, LockedException, LoaderException, NotReadyException -
testWriteAndIsReadyObj
@ParameterizedTest(name="{index} - inputFile = {0}, outputFile = {1}") @CsvSource({"books.obj,booksObj.bin","pitcher.obj,pitcherObj.bin","potro.obj,potroObj.bin"}) void testWriteAndIsReadyObj(String inputFile, String outputFile) throws IOException, LockedException, LoaderException, NotReadyException -
testWriteAndIsReadyBooksBinaryStlFile
@Test void testWriteAndIsReadyBooksBinaryStlFile() throws IOException, LockedException, LoaderException, NotReadyException -
testWriteAndIsReadyBooksAsciiStlFile
@Test void testWriteAndIsReadyBooksAsciiStlFile() throws IOException, LockedException, LoaderException, NotReadyException -
onWriteStart
- Specified by:
onWriteStartin interfaceMeshWriterListener
-
onWriteEnd
- Specified by:
onWriteEndin interfaceMeshWriterListener
-
onWriteProgressChange
- Specified by:
onWriteProgressChangein interfaceMeshWriterListener
-
onChunkAvailable
- Specified by:
onChunkAvailablein interfaceMeshWriterListener
-
onMaterialFileRequested
- Specified by:
onMaterialFileRequestedin interfaceMeshWriterListener
-
onValidateTexture
- Specified by:
onValidateTexturein interfaceMeshWriterListener
-
onDidValidateTexture
- Specified by:
onDidValidateTexturein interfaceMeshWriterListener
-
onTextureReceived
- Specified by:
onTextureReceivedin interfaceMeshWriterListener
-
onTextureDataAvailable
public File onTextureDataAvailable(MeshWriter writer, File textureFile, int textureWidth, int textureHeight) - Specified by:
onTextureDataAvailablein interfaceMeshWriterListener
-
onTextureDataProcessed
public void onTextureDataProcessed(MeshWriter writer, File textureFile, int textureWidth, int textureHeight) - Specified by:
onTextureDataProcessedin interfaceMeshWriterListener
-
checkLocked
-
resetListener
private void resetListener() -
isStartValid
private boolean isStartValid() -
isEndValid
private boolean isEndValid() -
isProgressValid
private boolean isProgressValid() -
isLockedValid
private boolean isLockedValid()
-