-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2556 from alicevision/dev/generateDepth
Generate depthmaps from sfmData and mesh
- Loading branch information
Showing
2 changed files
with
112 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
__version__ = "1.0" | ||
|
||
from meshroom.core import desc | ||
from meshroom.core.utils import VERBOSE_LEVEL | ||
|
||
|
||
class DepthMapRendering(desc.AVCommandLineNode): | ||
commandLine = "aliceVision_depthMapRendering {allParams}" | ||
|
||
category = "Utils" | ||
documentation = """ | ||
Using camera parameters and mesh, render depthmaps for each view | ||
""" | ||
|
||
inputs = [ | ||
desc.File( | ||
name="input", | ||
label="Input SfMData", | ||
description="Input SfMData file.", | ||
value="", | ||
), | ||
desc.File( | ||
name="mesh", | ||
label="Input Mesh", | ||
description="Input mesh file.", | ||
value="", | ||
), | ||
desc.ChoiceParam( | ||
name="verboseLevel", | ||
label="Verbose Level", | ||
description="Verbosity level (fatal, error, warning, info, debug, trace).", | ||
values=VERBOSE_LEVEL, | ||
value="info", | ||
), | ||
] | ||
|
||
outputs = [ | ||
desc.File( | ||
name="output", | ||
label="Folder", | ||
description="Output folder.", | ||
value=desc.Node.internalFolder, | ||
), | ||
desc.File( | ||
name="depth", | ||
label="Depth Maps", | ||
description="Rendered depth maps.", | ||
semantic="image", | ||
value=desc.Node.internalFolder + "<VIEW_ID>_depthMap.exr", | ||
group="", # do not export on the command line | ||
), | ||
desc.File( | ||
name="mask", | ||
label="Masks", | ||
description="Masks.", | ||
semantic="image", | ||
value=desc.Node.internalFolder + "<VIEW_ID>_mask.exr", | ||
group="", # do not export on the command line | ||
), | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
__version__ = "1.0" | ||
|
||
from meshroom.core import desc | ||
from meshroom.core.utils import VERBOSE_LEVEL | ||
|
||
|
||
class NormalMapRendering(desc.AVCommandLineNode): | ||
commandLine = "aliceVision_normalMapRendering {allParams}" | ||
|
||
category = "Utils" | ||
documentation = """ | ||
Using camera parameters and mesh, render normalmaps for each view | ||
""" | ||
|
||
inputs = [ | ||
desc.File( | ||
name="input", | ||
label="Input SfMData", | ||
description="Input SfMData file.", | ||
value="", | ||
), | ||
desc.File( | ||
name="mesh", | ||
label="Input Mesh", | ||
description="Input mesh file.", | ||
value="", | ||
), | ||
desc.ChoiceParam( | ||
name="verboseLevel", | ||
label="Verbose Level", | ||
description="Verbosity level (fatal, error, warning, info, debug, trace).", | ||
values=VERBOSE_LEVEL, | ||
value="info", | ||
), | ||
] | ||
|
||
outputs = [ | ||
desc.File( | ||
name="output", | ||
label="Folder", | ||
description="Output folder.", | ||
value=desc.Node.internalFolder, | ||
), | ||
desc.File( | ||
name="normal", | ||
label="Normal Maps", | ||
description="Rendered normal maps.", | ||
semantic="image", | ||
value=desc.Node.internalFolder + "<VIEW_ID>_normalMap.exr", | ||
group="", # do not export on the command line | ||
), | ||
] |