Skip to content

Commit

Permalink
codestyle
Browse files Browse the repository at this point in the history
  • Loading branch information
mi-sts committed May 19, 2024
1 parent f18687f commit b0b9d90
Showing 1 changed file with 3 additions and 5 deletions.
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package solve.rendering.engine.core.renderers

import org.joml.Vector2f
import org.joml.Vector3f
import org.joml.Vector4f
import solve.constants.ShadersPointAssociationFragmentPath
import solve.constants.ShadersPointAssociationVertexPath
Expand Down Expand Up @@ -100,8 +99,8 @@ class PointAssociationsRenderer(
NonOpaqueMaxLineWidth
)
val nonOpaqueRectNormalOffset = Vector2f(normalVector) *
(AssociationLineWidth + nonOpaqueLineRectWidth) / 2f / window.camera.zoom /
DefaultLocalVerticesPositionsDivider
(AssociationLineWidth + nonOpaqueLineRectWidth) / 2f / window.camera.zoom /
DefaultLocalVerticesPositionsDivider
drawLineRectVertices(
lineStartShaderPosition + nonOpaqueRectNormalOffset,
lineFinishShaderPosition + nonOpaqueRectNormalOffset,
Expand All @@ -119,7 +118,6 @@ class PointAssociationsRenderer(
normalVector
)
}

}
}

Expand All @@ -135,7 +133,7 @@ class PointAssociationsRenderer(
val centerLinePoints = listOf(rectCenterStartPoint, rectCenterFinishPoint)
centerLinePoints.forEachIndexed { sideIndex, linePoint ->
val pointToVertexVector = Vector2f(normalVector) * (rectWidth / 2f) / window.camera.zoom /
DefaultLocalVerticesPositionsDivider
DefaultLocalVerticesPositionsDivider

val upperVertexPosition = linePoint + pointToVertexVector
val bottomVertexPosition = linePoint - pointToVertexVector
Expand Down

0 comments on commit b0b9d90

Please sign in to comment.