code wiki / (root) / nx_normal_encoding_contract.nx

nx_normal_encoding_contract.nx

buildroot/runtime/nx_normal_encoding_contract.nx

1396 B32 linesdepth 0pulls 0 transitivereach 209 importersview sourcekind librarytopic normal
docsdependenciesstructsconstsfunctions

about

Shared byte transfer contract used by the existing baker and renderer.

dependencies 0 imports · 9 importers

nx_normal_encoding_contract.nx nx_cast_scene_light_candidate_t364 nx_cast_shader_src.nx nx_cast_shader_static_t335.nx nx_game_normal_encoding_emit.nx nx_gltf_render_descriptor_before_s nx_gltf_render_descriptor_candidat nx_gltf_render_descriptor_normal_t nx_gltf_render_multipart_candidate nx_nxa_texbake_lib.nx

imports: none

imported by: nx_cast_scene_light_candidate_t364.nxnx_cast_shader_src.nxnx_cast_shader_static_t335.nxnx_game_normal_encoding_emit.nxnx_gltf_render_descriptor_before_static_t338.nxnx_gltf_render_descriptor_candidate_t181.nxnx_gltf_render_descriptor_normal_t281.nxnx_gltf_render_multipart_candidate_t345.nxnx_nxa_texbake_lib.nx

structs

none

consts

2const NTB_N_MID: i64 = 128
3const NTB_N_SCALE: i64 = 127
4const NTB_GREY_MAX: i64 = 255
9const NTB_NORMAL_ENCODING_NATIVE_MID_SCALE: i64 = 1
10const NTB_NORMAL_ENCODING_GLTF_UNORM: i64 = 2

functions

11func ntb_normal_decode_rgb8(encoding:i64,r:i64,g:i64,b:i64,out3:*i64)->i64
26func ntb_normal_encoding_admit(declared:i64,encoding:i64)->i64