Files
test2/source/blender/compositor/intern/COM_ChunkOrderHotspot.cc

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

20 lines
433 B
C++
Raw Normal View History

/* SPDX-FileCopyrightText: 2011 Blender Authors
*
* SPDX-License-Identifier: GPL-2.0-or-later */
#include "COM_ChunkOrderHotspot.h"
#include <cmath>
namespace blender::compositor {
double ChunkOrderHotspot::calc_distance(int x, int y)
{
int dx = this->x - x;
int dy = this->y - y;
double result = sqrt(double(dx * dx + dy * dy));
result += double(this->addition);
return result;
}
} // namespace blender::compositor