Skip to content

Port of Morten S. Mikkelsen's tangent space algorithm in Odin

License

Notifications You must be signed in to change notification settings

wrapperup/odin-mikktspace

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Odin MikkTSpace

Port of Morten S. Mikkelsen's Tangent Space algorithm in Odin.

Usage

import mikk "mikktspace"

mesh_data := ...

interface := mikk.Interface {
    get_num_faces            = get_num_faces,
    get_num_vertices_of_face = get_num_vertices_of_face,
    get_position             = get_position,
    get_normal               = get_normal,
    get_tex_coord            = get_tex_coord,
    set_t_space_basic        = set_t_space_basic,
}

ctx := mikk.Context {
    interface = &interface,
    user_data  = &mesh_data,
}

ok := mikk.generate_tangents(&ctx)

Full example can be found here

License

zlib License

About

Port of Morten S. Mikkelsen's tangent space algorithm in Odin

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages