From 7dd28c93e2b669c4327d43ae8b608c15192db396 Mon Sep 17 00:00:00 2001 From: jules Date: Tue, 5 May 2009 12:00:57 +0000 Subject: [PATCH] linux window z-order fix; small change to make audio plugin host demo compile; fix for assembly language in graphics rendering on gcc. --- .../platform_specific_code/juce_linux_Windowing.cpp | 6 ++++++ .../build/mac/PluginHost.xcodeproj/project.pbxproj | 4 ++-- juce_amalgamated.cpp | 10 +++++++++- juce_amalgamated.h | 2 +- .../audio/devices/juce_AudioDeviceManager.h | 2 +- .../contexts/juce_LowLevelGraphicsSoftwareRenderer.cpp | 4 +++- 6 files changed, 22 insertions(+), 6 deletions(-) diff --git a/build/linux/platform_specific_code/juce_linux_Windowing.cpp b/build/linux/platform_specific_code/juce_linux_Windowing.cpp index 2c07d3d159..a399468c1a 100644 --- a/build/linux/platform_specific_code/juce_linux_Windowing.cpp +++ b/build/linux/platform_specific_code/juce_linux_Windowing.cpp @@ -1090,6 +1090,12 @@ public: SubstructureRedirectMask | SubstructureNotifyMask, &ev); + XWindowAttributes attr; + XGetWindowAttributes (display, windowH, &attr); + + if (attr.override_redirect) + XRaiseWindow (display, windowH); + XSync (display, False); handleBroughtToFront(); diff --git a/extras/audio plugin host/build/mac/PluginHost.xcodeproj/project.pbxproj b/extras/audio plugin host/build/mac/PluginHost.xcodeproj/project.pbxproj index 56e0dd48cb..a017a5bc38 100644 --- a/extras/audio plugin host/build/mac/PluginHost.xcodeproj/project.pbxproj +++ b/extras/audio plugin host/build/mac/PluginHost.xcodeproj/project.pbxproj @@ -242,7 +242,7 @@ GCC_ENABLE_FIX_AND_CONTINUE = YES; GCC_OPTIMIZATION_LEVEL = 0; PRODUCT_NAME = "Juce Plugin Host"; - USER_HEADER_SEARCH_PATHS = "~/stuff/vstsdk2.4 $(inherited)"; + USER_HEADER_SEARCH_PATHS = "~/SDKs/vstsdk2.4 $(inherited)"; ZERO_LINK = NO; }; name = Debug; @@ -253,7 +253,7 @@ buildSettings = { PRODUCT_NAME = "Juce Plugin Host"; SEPARATE_STRIP = YES; - USER_HEADER_SEARCH_PATHS = "~/stuff/vstsdk2.4 $(inherited)"; + USER_HEADER_SEARCH_PATHS = "~/SDKs/vstsdk2.4 $(inherited)"; ZERO_LINK = NO; }; name = Release; diff --git a/juce_amalgamated.cpp b/juce_amalgamated.cpp index 44dd7b68ee..87c79c3d9e 100644 --- a/juce_amalgamated.cpp +++ b/juce_amalgamated.cpp @@ -78203,7 +78203,8 @@ static void blendRectRGB (uint8* pixels, const int w, int h, const int stride, c __asm emms #else __asm__ __volatile__ ( - "movq %[aaaa], %%mm1 \n" + "\tpush %%ebx \n" + "\tmovq %[aaaa], %%mm1 \n" "\tmovq %[rgb0], %%mm2 \n" "\tpxor %%mm7, %%mm7 \n" ".lineLoop2: \n" @@ -78231,6 +78232,7 @@ static void blendRectRGB (uint8* pixels, const int w, int h, const int stride, c "\tadd %%edi, %%esi \n" "\tdec %%ecx \n" "\tjg .lineLoop2 \n" + "\tpop %%ebx \n" "\temms \n" : /* No output registers */ : [aaaa] "m" (aaaa), /* Input registers */ @@ -262349,6 +262351,12 @@ public: SubstructureRedirectMask | SubstructureNotifyMask, &ev); + XWindowAttributes attr; + XGetWindowAttributes (display, windowH, &attr); + + if (attr.override_redirect) + XRaiseWindow (display, windowH); + XSync (display, False); handleBroughtToFront(); diff --git a/juce_amalgamated.h b/juce_amalgamated.h index d1b3fda28f..f5f221a3ed 100644 --- a/juce_amalgamated.h +++ b/juce_amalgamated.h @@ -34273,7 +34273,7 @@ private: device selection/sample-rate/latency controls. To use an AudioDeviceManager, create one, and use initialise() to set it up. Then - call setAudioCallback() to register your audio callback with it, and use that to process + call addAudioCallback() to register your audio callback with it, and use that to process your audio data. The manager also acts as a handy hub for incoming midi messages, allowing a diff --git a/src/juce_appframework/audio/devices/juce_AudioDeviceManager.h b/src/juce_appframework/audio/devices/juce_AudioDeviceManager.h index b0242174be..89fc407f90 100644 --- a/src/juce_appframework/audio/devices/juce_AudioDeviceManager.h +++ b/src/juce_appframework/audio/devices/juce_AudioDeviceManager.h @@ -62,7 +62,7 @@ device selection/sample-rate/latency controls. To use an AudioDeviceManager, create one, and use initialise() to set it up. Then - call setAudioCallback() to register your audio callback with it, and use that to process + call addAudioCallback() to register your audio callback with it, and use that to process your audio data. The manager also acts as a handy hub for incoming midi messages, allowing a diff --git a/src/juce_appframework/gui/graphics/contexts/juce_LowLevelGraphicsSoftwareRenderer.cpp b/src/juce_appframework/gui/graphics/contexts/juce_LowLevelGraphicsSoftwareRenderer.cpp index 384d3c0770..b67d89ee56 100644 --- a/src/juce_appframework/gui/graphics/contexts/juce_LowLevelGraphicsSoftwareRenderer.cpp +++ b/src/juce_appframework/gui/graphics/contexts/juce_LowLevelGraphicsSoftwareRenderer.cpp @@ -225,7 +225,8 @@ static void blendRectRGB (uint8* pixels, const int w, int h, const int stride, c __asm emms #else __asm__ __volatile__ ( - "movq %[aaaa], %%mm1 \n" + "\tpush %%ebx \n" + "\tmovq %[aaaa], %%mm1 \n" "\tmovq %[rgb0], %%mm2 \n" "\tpxor %%mm7, %%mm7 \n" ".lineLoop2: \n" @@ -253,6 +254,7 @@ static void blendRectRGB (uint8* pixels, const int w, int h, const int stride, c "\tadd %%edi, %%esi \n" "\tdec %%ecx \n" "\tjg .lineLoop2 \n" + "\tpop %%ebx \n" "\temms \n" : /* No output registers */ : [aaaa] "m" (aaaa), /* Input registers */