Is there a way to make a dark/low light SceneKit scene?

前端 未结 2 1622
误落风尘
误落风尘 2021-01-14 00:02

I\'ve searched and there doesn\'t appear to be a way to make a dark SceneKit scene... As in a scene with low lighting. I\'ve removed all lights from my scene, set my autoena

相关标签:
2条回答
  • 2021-01-14 00:20

    SCNLightingModelConstant is worth a look.

    The SceneKit demos (code provided at apple.com) from 2014 and 2013 are quite dark. There's plenty to learn from there.

    0 讨论(0)
  • 2021-01-14 00:24

    Had to try this for myself, as it didn't sound right. Removing all lights from the default SceneKit game template does indeed result in a model lit with an ambient light. I expect it's some kind of default that kicks into action when SceneKit identifies you have no lights in your scene.

    Adding a black ambient light doesn't seem to change this, however adding a single dark non-ambient (omni, directional, spot) does result in a dark scene. The following image is with a dark gray omni light, and no ambient light.

    I don't think this matters too much in real use, you'd be unlikely to have a scene with no non-ambient lights. Certainly understand the confusion in this instance however.

    0 讨论(0)
提交回复
热议问题