mirror of
https://github.com/badaix/snapcast.git
synced 2025-06-06 04:41:44 +02:00
Fix Windows warnings
This commit is contained in:
parent
ade0ee7be3
commit
e5047f1aff
12 changed files with 167 additions and 165 deletions
|
@ -51,7 +51,7 @@ public:
|
|||
}
|
||||
|
||||
/// Median as mean over N values around the median
|
||||
T median(unsigned int mean = 1) const
|
||||
T median(uint16_t mean = 1) const
|
||||
{
|
||||
if (buffer.empty())
|
||||
return 0;
|
||||
|
@ -61,12 +61,12 @@ public:
|
|||
return tmpBuffer[tmpBuffer.size() / 2];
|
||||
else
|
||||
{
|
||||
unsigned int low = tmpBuffer.size() / 2;
|
||||
unsigned int high = low;
|
||||
uint16_t low = static_cast<uint16_t>(tmpBuffer.size()) / 2;
|
||||
uint16_t high = low;
|
||||
low -= mean / 2;
|
||||
high += mean / 2;
|
||||
T result((T)0);
|
||||
for (unsigned int i = low; i <= high; ++i)
|
||||
for (uint16_t i = low; i <= high; ++i)
|
||||
{
|
||||
result += tmpBuffer[i];
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue