mirror of
https://github.com/The-Powder-Toy/The-Powder-Toy.git
synced 2025-08-24 17:02:55 +02:00
Fix a few warnings
This commit is contained in:
@@ -847,7 +847,7 @@ void Renderer::draw_grav()
|
|||||||
{
|
{
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
auto np = Vec2<float>(p.X * CELL, p.Y * CELL);
|
auto np = Vec2{ float(p.X * CELL), float(p.Y * CELL) };
|
||||||
auto dist = agx + agy;
|
auto dist = agx + agy;
|
||||||
for (auto i = 0; i < 4; ++i)
|
for (auto i = 0; i < 4; ++i)
|
||||||
{
|
{
|
||||||
|
@@ -81,7 +81,7 @@ void ScrollPanel::XOnMouseDown(int x, int y, unsigned int button)
|
|||||||
scrollbarSelected = true;
|
scrollbarSelected = true;
|
||||||
scrollbarInitialYOffset = int(offsetY);
|
scrollbarInitialYOffset = int(offsetY);
|
||||||
}
|
}
|
||||||
initialOffsetY = offsetY;
|
initialOffsetY = int(offsetY);
|
||||||
scrollbarInitialYClick = y - Position.Y;
|
scrollbarInitialYClick = y - Position.Y;
|
||||||
scrollbarClickLocation = 100;
|
scrollbarClickLocation = 100;
|
||||||
}
|
}
|
||||||
|
@@ -179,7 +179,7 @@ void GravityImpl::Init()
|
|||||||
fftwf_execute(kernelYForward.get());
|
fftwf_execute(kernelYForward.get());
|
||||||
|
|
||||||
//clear padded gravmap
|
//clear padded gravmap
|
||||||
std::memset(massBig.get(), 0.f, blocks.X * blocks.Y * sizeof(float));
|
std::fill(massBig.get(), massBig.get() + blocks.X * blocks.Y, 0.f);
|
||||||
|
|
||||||
thr = std::thread([this]() {
|
thr = std::thread([this]() {
|
||||||
while (true)
|
while (true)
|
||||||
|
Reference in New Issue
Block a user