Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Sign in
  • nomad-3d-editor nomad-3d-editor
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 4
    • Issues 4
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 0
    • Merge requests 0
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Container Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Instrument ControlInstrument Control
  • ProtosProtos
  • Nomad 3DNomad 3D
  • nomad-3d-editornomad-3d-editor
  • Wiki
  • Home

Home · Changes

Page history
improved material math authored Jul 20, 2017 by Ivan Dages's avatar Ivan Dages
Show whitespace changes
Inline Side-by-side
home.md
View page @ c08567b9
......@@ -54,12 +54,8 @@ The typical workflow in the editor is to modify the model in order to make it co
The visual properties of a Nomad 3D model are stored as [Phong materials](https://en.wikipedia.org/wiki/Phong_shading), one for each component. However the viewer uses [Physically based Rendering (PBR)](https://www.marmoset.co/posts/basic-theory-of-physically-based-rendering/) to get a more realistic result. The conversion between the two illumination models is not usual so a simple and arbitrary conversion is applied :
$`pbr.color = phong.diffuse `$
$`pbr.metalness = cap \left( ||phong.specular||, 0, 1 \right) `$
$`pbr.roughness = 1 - cap \left( \frac{phong.shininess}{maxShininess}, 0, 1 \right) `$
where $`maxShininess = 250`$.
* $`pbr.color = phong.diffuse `$
* $`pbr.metalness = cap \left( ||phong.specular||, 0, 1 \right) `$
* $`pbr.roughness = 1 - cap \left( \frac{phong.shininess}{maxShininess}, 0, 1 \right) `$, where $`maxShininess = 250`$.
The Phong diffuse color defines the base color of the object. The specular color (which is usually a shade of gray) defines the metalness of the object : white for metallic components, black for non-metal ones. The shininess defines the roughness of the object : the more it is shiny the less it is rough (with an arbitrary maximum shininess).
Clone repository
  • Home