forked from bedohswe/p3he
A partial fix for rendering finite lines.
This commit is contained in:
parent
56228bc8b1
commit
2b0e9cbeef
4
draw.py
4
draw.py
@ -1,7 +1,7 @@
|
||||
from cmath import exp
|
||||
|
||||
from constants import I, BLACK
|
||||
from gyro import MobiusInt, MobiusAdd, MobiusDist, cDot
|
||||
from gyro import MobiusInt, MobiusAdd, MobiusDist, cDot, Poincare2Klein
|
||||
from lines import cBetween
|
||||
|
||||
from numba import jit, byte, double, prange, optional
|
||||
@ -38,7 +38,7 @@ def draw(level,gPlayer,fov,res):
|
||||
if cDot(rot,MobiusAdd(cInt,-gPlayer.cPos)) > 0:
|
||||
continue
|
||||
rDist = MobiusDist(cInt,gPlayer.cPos)*1.1
|
||||
if j.isFinite and not cBetween(j.pointA,j.pointB,cInt):
|
||||
if j.isFinite and not cBetween(Poincare2Klein(j.pointA),Poincare2Klein(j.pointB),Poincare2Klein(cInt)):
|
||||
continue
|
||||
if m is None:
|
||||
m = DrawnSegment(rDist,j.color)
|
||||
|
Loading…
Reference in New Issue
Block a user