47 lines
1.3 KiB
Batchfile
47 lines
1.3 KiB
Batchfile
::This script was created by Capturing Reality ©
|
|
|
|
:: Switch off console output.
|
|
@echo on
|
|
|
|
call SetVariables.bat
|
|
|
|
:: Variable storing path to images for creating model.
|
|
set ImagesGeometry=%RootFolder%\%1\.geometry
|
|
|
|
:: Variable storing path to images for texturing model.
|
|
set ImagesTexture=%RootFolder%\%1\.texture.TextureLayer
|
|
|
|
:: A path to the metadata folder.
|
|
set Metadata=%RootFolder%\Metadata
|
|
|
|
:: Variable storing path to xmp metadata.
|
|
set XMPMetadata=%Metadata%\xmp
|
|
|
|
:: Variable storing the path to the reconstruction region file.
|
|
set ReconstructionRegion=%Metadata%\ReconstructionRegion.rcbox
|
|
|
|
:: Variable storing name of file with parameters for exporting model to .obj file format.
|
|
set ModelExportParams=%Metadata%\ModelExportParams.xml
|
|
|
|
|
|
:: Copies XMP files from metadata folder to geometry image folder.
|
|
xcopy /Y %XmpMetadata%\*.xmp %ImagesGeometry%\
|
|
|
|
:: Run RealityCapture.
|
|
%RealityCaptureExe% -addFolder %ImagesGeometry% ^
|
|
-addFolder %ImagesTexture% ^
|
|
-set "sfmEnableCameraPrior=true" ^
|
|
-set "ImageLayerForTexturing=TextureLayer" ^
|
|
-align ^
|
|
-setReconstructionRegion %ReconstructionRegion% ^
|
|
-calculateNormalModel ^
|
|
-simplify 1000000 ^
|
|
-calculateTexture ^
|
|
-exportModel "Model 2" "%RootFolder%\%1\Model_%1.obj" "%ModelExportParams%" ^
|
|
-save %RootFolder%\%1\Project_%1.rcproj ^
|
|
-quit
|
|
|
|
|
|
|
|
|