mirror of
https://github.com/blender/blender
synced 2026-10-25 03:07:01 +03:00
14 lines
443 B
Text
14 lines
443 B
Text
/* SPDX-FileCopyrightText: 2011-2022 Blender Foundation
|
|
*
|
|
* SPDX-License-Identifier: Apache-2.0 */
|
|
|
|
#include "stdcycles.h"
|
|
|
|
shader node_normal(normal direction = normal(0.0, 0.0, 0.0),
|
|
normal NormalIn = normal(0.0, 0.0, 0.0),
|
|
output normal NormalOut = normal(0.0, 0.0, 0.0),
|
|
output float Dot = 1.0)
|
|
{
|
|
NormalOut = normalize(direction);
|
|
Dot = dot(NormalOut, normalize(NormalIn));
|
|
}
|