Add orthogonal projection and unit tests
This commit is contained in:
1 parent
05ea67eed0
commit
521c35f621
2 files changed
+40
No files matched your search
@@ -0,0 +1,15 @@
|
||||
import pytest
|
||||
|
||||
from matrixmania.compute import project_ortho
|
||||
|
||||
|
||||
def test_project_ortho_default():
|
||||
"""Projektionsfunktion ohne Skalierung"""
|
||||
point = (1.0, 2.0, 3.0)
|
||||
assert project_ortho(point) == (1.0, 2.0)
|
||||
|
||||
|
||||
def test_project_ortho_scaled():
|
||||
"""Projektionsfunktion mit Skalierung"""
|
||||
point = (1.0, 2.0, 3.0)
|
||||
assert project_ortho(point, scale=100) == (100.0, 200.0)
|
||||
Reference in new issue
Block a user