1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-17 00:44:19 +00:00

Workarounds for some mingw build problems.

This commit is contained in:
jules 2014-03-19 11:23:52 +00:00
parent be47fc8e6b
commit dfda7c77fc
5 changed files with 14 additions and 8 deletions

View file

@ -36,6 +36,10 @@
#include "AppConfig.h"
#include "juce_audio_basics.h"
#if JUCE_MINGW && ! defined (__SSE2__)
#define JUCE_USE_SSE_INTRINSICS 0
#endif
#ifndef JUCE_USE_SSE_INTRINSICS
#define JUCE_USE_SSE_INTRINSICS 1
#endif

View file

@ -61,6 +61,7 @@ namespace FlacNamespace
#define FLAC__HAS_X86INTRIN 1
#endif
#undef __STDC_LIMIT_MACROS
#define __STDC_LIMIT_MACROS 1
#define flac_max jmax
#define flac_min jmin

View file

@ -120,7 +120,8 @@ namespace TTFNameExtractor
for (int i = 0; i < (int) ByteOrder::swapIfLittleEndian (offsetTable.numTables); ++i)
{
TableDirectory tableDirectory = { 0 };
TableDirectory tableDirectory;
zerostruct (tableDirectory);
input.read (&tableDirectory, sizeof (tableDirectory));
if (String (tableDirectory.tag, sizeof (tableDirectory.tag)).equalsIgnoreCase ("name"))

View file

@ -3229,11 +3229,11 @@ void Desktop::setKioskComponent (Component* kioskModeComponent, bool enableOrDis
struct MonitorInfo
{
MonitorInfo (Rectangle<int> rect, bool main, double d) noexcept
: isMain (main), bounds (rect), dpi (d) {}
: bounds (rect), dpi (d), isMain (main) {}
Rectangle<int> bounds;
bool isMain;
double dpi;
bool isMain;
};
static BOOL CALLBACK enumMonitorsProc (HMONITOR hm, HDC, LPRECT r, LPARAM userInfo)

View file

@ -94,12 +94,12 @@ public:
}
/** Returns a new matrix from the given frustrum values. */
static Matrix3D fromFrustum (Type left, Type right, Type bottom, Type top, Type near, Type far) noexcept
static Matrix3D fromFrustum (Type left, Type right, Type bottom, Type top, Type nearDistance, Type farDistance) noexcept
{
return Matrix3D ((2.0f * near) / (right - left), 0.0f, 0.0f, 0.0f,
0.0f, (2.0f * near) / (top - bottom), 0.0f, 0.0f,
(right + left) / (right - left), (top + bottom) / (top - bottom), -(far + near) / (far - near), -1.0f,
0.0f, 0.0f, -(2.0f * far * near) / (far - near), 0.0f);
return Matrix3D ((2.0f * nearDistance) / (right - left), 0.0f, 0.0f, 0.0f,
0.0f, (2.0f * nearDistance) / (top - bottom), 0.0f, 0.0f,
(right + left) / (right - left), (top + bottom) / (top - bottom), -(farDistance + nearDistance) / (farDistance - nearDistance), -1.0f,
0.0f, 0.0f, -(2.0f * farDistance * nearDistance) / (farDistance - nearDistance), 0.0f);
}
/** Multiplies this matrix by another. */