Skip to content

Commit

Permalink
smaller arrows in rendering cell connections
Browse files Browse the repository at this point in the history
  • Loading branch information
chrxh committed Aug 31, 2024
1 parent 35ebc46 commit 1730394
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions source/EngineGpuKernels/RenderingKernels.cu
Original file line number Diff line number Diff line change
Expand Up @@ -556,14 +556,14 @@ __global__ void cudaDrawCells(
auto direction = Math::normalized(arrowEnd - otherCellImagePos);
{
float2 arrowPartStart = {-direction.x + direction.y, -direction.x - direction.y};
arrowPartStart = arrowPartStart * zoom / 8 + arrowEnd;
arrowPartStart = arrowPartStart * zoom / 14 + arrowEnd;
if (isLineVisible(arrowPartStart, arrowEnd, universeImageSize)) {
drawLine(arrowPartStart, arrowEnd, lineColor, imageData, imageSize, 0.5f);
}
}
{
float2 arrowPartStart = {-direction.x - direction.y, direction.x - direction.y};
arrowPartStart = arrowPartStart * zoom / 8 + arrowEnd;
arrowPartStart = arrowPartStart * zoom / 14 + arrowEnd;
if (isLineVisible(arrowPartStart, arrowEnd, universeImageSize)) {
drawLine(arrowPartStart, arrowEnd, lineColor, imageData, imageSize, 0.5f);
}
Expand Down

0 comments on commit 1730394

Please sign in to comment.