64 bit plugins -what support is available in Juce?

Discuss issues relating to audio plugins

64 bit plugins -what support is available in Juce?

Postby valhallasound » Wed Jan 13, 2010 5:05 am

Hi all:

Apple just announced Logic 9.1, which supports 64 bit plugins natively, and in 64-bit mode runs 32 bit plugins via a bridge. Other hosts are working on 64 bit versions of their hosts.

So...how do we write 64-bit plugins in Juce? The 64-bit processing doesn't seem that confusing (I can figure out where to replace float with double, or come up with a MY_FLOAT definition), but how do we specify which render function to call? Obviously, we need to support both 32 bit and 64 bit plugins for the time being. And do the various setParameter() and getParameter() functions need to be 64 bit?

Feel free to point me to other threads that discuss this, if need be. The whole 64 bit thing seems like a pain to deal with, as very few DSP operations need precision beyond 32 bit floats (low frequency resonant/notch filters and some level detectors being the main exceptions I can think up). But it looks unavoidable at this point.

Thanks,

Sean Costello
valhallasound
JUCE UberWeenie
 
Posts: 393
Joined: Wed Apr 09, 2008 1:30 am

Re: 64 bit plugins -what support is available in Juce?

Postby otristan » Wed Jan 13, 2010 10:29 am

64bits plugins are not 64bits processing plugins.
They just run in 64bits memory address model
otristan
JUCE UberWeenie
 
Posts: 650
Joined: Sat Mar 03, 2007 3:03 pm
Location: Paris

Re: 64 bit plugins -what support is available in Juce?

Postby Mikey » Wed Jan 13, 2010 4:04 pm

Yes, I just downloaded the new Logic and I must say that 32-bit bridge app is awkward. So I need to build a 64-bit version. So far I'm stumbling. I was successfully building a 32-bit Cocoa version. It appears that I need to strip out the Carbon support in order to go 64. If any of us make discoveries (or have prior knowledge) about doing that, let's share it here.
Mikey
JUCE UberWeenie
 
Posts: 226
Joined: Fri Feb 20, 2009 7:36 pm
Location: The Rockies

Re: 64 bit plugins -what support is available in Juce?

Postby jules » Wed Jan 13, 2010 5:25 pm

It's just a setting in XCode. Set it to build a 32/64-bit binary. Simple as that.
User avatar
jules
Fearless Leader
 
Posts: 17204
Joined: Mon Sep 06, 2004 9:03 am
Location: London, UK

Re: 64 bit plugins -what support is available in Juce?

Postby Mikey » Wed Jan 13, 2010 6:44 pm

jules wrote:It's just a setting in XCode. Set it to build a 32/64-bit binary. Simple as that.

For you maybe. It took a while to get a successful link. The key seems to be the 'Build Active Architecture Only" checkbox. It must be checked.

But even after that, there's a problem. If I launch Logic 9.1 in 32 bit mode,, a 32/64 plug is verified by AUval and loads and runs properly. But if I launch Logic in 64-bit mode, Auval gives me the following errors:

ERROR: Cannot get Component's Name strings
ERROR: Error from retrieving Component Version: 4294967246


Any ideas?
Mikey
JUCE UberWeenie
 
Posts: 226
Joined: Fri Feb 20, 2009 7:36 pm
Location: The Rockies

Re: 64 bit plugins -what support is available in Juce?

Postby otristan » Wed Jan 13, 2010 7:03 pm

Should'nt you add stuff to the "Other Rez Flags" ?
otristan
JUCE UberWeenie
 
Posts: 650
Joined: Sat Mar 03, 2007 3:03 pm
Location: Paris

Re: 64 bit plugins -what support is available in Juce?

Postby Mikey » Wed Jan 13, 2010 7:41 pm

otristan wrote:Should'nt you add stuff to the "Other Rez Flags" ?

Looks quite possible, when I see the current values:

-d ppc_$ppc -d i386_$i386 -I / -I /System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/CarbonCore.framework/Versions/A/Headers

My problem is that I'm pretty much a straight DSP type and I have only the vaguest clue what Rez does and how it works. I'm trying to get schooled, but my earliest tweaks to these flags did nothing.
Mikey
JUCE UberWeenie
 
Posts: 226
Joined: Fri Feb 20, 2009 7:36 pm
Location: The Rockies

Re: 64 bit plugins -what support is available in Juce?

Postby jules » Wed Jan 13, 2010 8:01 pm

The key seems to be the 'Build Active Architecture Only" checkbox. It must be checked.


Surely checking that box would override the build setting and just do a normal 32-bit one...?
User avatar
jules
Fearless Leader
 
Posts: 17204
Joined: Mon Sep 06, 2004 9:03 am
Location: London, UK

Re: 64 bit plugins -what support is available in Juce?

Postby Mikey » Wed Jan 13, 2010 8:47 pm

jules wrote:
The key seems to be the 'Build Active Architecture Only" checkbox. It must be checked.


Surely checking that box would override the build setting and just do a normal 32-bit one...?

That would have been my initial thought, but I can't build Juce 1.50 if I don't set that flag. Here are my settings:
Architectures: 32/64-bit Universal
Base SDK: Mac OSX 10.5
Valid Architectures: i386 ppc ppc64 ppc7400 ppc970 x86-64

If Build Active Architecture Only is checked, it builds
If it's unchecked, I get five errors, beginning with these two:
juce_mac_NSViewComponentPeer.mm:1502: error: 'kUIModeAllSuppressed' was not declared in this scope
juce_mac_NSViewComponentPeer.mm:1502: error: 'kUIOptionAutoShowMenuBar' was not declared in this scope



The value (0 or 1) of JUCE_SUPPORT_CARBON has no effect here.
Mikey
JUCE UberWeenie
 
Posts: 226
Joined: Fri Feb 20, 2009 7:36 pm
Location: The Rockies

Re: 64 bit plugins -what support is available in Juce?

Postby jules » Wed Jan 13, 2010 9:01 pm

You're probably linking to an old version of the SDK? Try using the 10.6 SDK.

I can certainly build 64-bit binaries here with no problem, so there's no problem with the code itself.
User avatar
jules
Fearless Leader
 
Posts: 17204
Joined: Mon Sep 06, 2004 9:03 am
Location: London, UK

Re: 64 bit plugins -what support is available in Juce?

Postby Mikey » Wed Jan 13, 2010 10:58 pm

Jules,
I'm now using the 10.6 SDK under XCode 3.2.1. No matter what I do, I can't build the Juce library with 64-bit Intel code. I've gone so far as to re-download the juce package, just to make sure I hadn't messed anything up. I even booted my system (8-core Nehalem) up with a 64-bit kernel. Nothing. Nada.

I always have five symbols undefined. One of those is kUIModeAllSuppressed. I have found that this and the other symbols are defined in MacApplication.h, which is buried deep in the Carbon framework. But this file isn't included anywhere in the juce library build.

Does your success in building 64-bit extend to the library, or are you simply including the amalgamated file?

FWIW, I have other libraries that I use in these plugs. No problem building them in 32/64.
Mikey
JUCE UberWeenie
 
Posts: 226
Joined: Fri Feb 20, 2009 7:36 pm
Location: The Rockies

Re: 64 bit plugins -what support is available in Juce?

Postby vishvesh » Thu Jan 14, 2010 3:24 am

Sounds like a problem similar to this. http://www.rawmaterialsoftware.com/viewtopic.php?f=4&t=4434. Am not sure but I think somebody had fixed it.

Please check the Macintosh specific threads.
Best Regards,
Vishvesh
User avatar
vishvesh
JUCE UberWeenie
 
Posts: 504
Joined: Fri Aug 01, 2008 10:16 am
Location: Bangalore, India.

Re: 64 bit plugins -what support is available in Juce?

Postby vishvesh » Thu Jan 14, 2010 3:38 am

Looks like we are in luck. The solution http://www.rawmaterialsoftware.com/viewtopic.php?f=4&t=4584.

Are you using the release version of juce or the one from his tip?
Best Regards,
Vishvesh
User avatar
vishvesh
JUCE UberWeenie
 
Posts: 504
Joined: Fri Aug 01, 2008 10:16 am
Location: Bangalore, India.

Re: 64 bit plugins -what support is available in Juce?

Postby Mikey » Thu Jan 14, 2010 5:03 am

vishvesh wrote:Looks like we are in luck. The solution http://www.rawmaterialsoftware.com/viewtopic.php?f=4&t=4584.

Are you using the release version of juce or the one from his tip?

I'm using the release version (for now). It's getting to be rather late now, so I'll have to put this off until the morning. Thanks for digging this up.
Mikey
JUCE UberWeenie
 
Posts: 226
Joined: Fri Feb 20, 2009 7:36 pm
Location: The Rockies

Re: 64 bit plugins -what support is available in Juce?

Postby jpo » Thu Jan 14, 2010 6:08 pm

Using latest juce tip, I have just run my plugin as a 64-bit powerpc audiounit on a leopard mac (in AU Lab) - the gui is fine (as long as you don't try to build the carbon one). I can not yet test on a x86_64 box, but I'm pretty confident it will work. In the rez flag I have added -d ppc64_YES -d x86_64_YES , but I'm not sure if it helped or not (I had some problems to get the 64-bit audiounit recognized at first, not sure why..)

What about VST by the way, does a 64-bit mac VST host exist ?
jpo
JUCE UberWeenie
 
Posts: 336
Joined: Thu Mar 20, 2008 2:45 pm

Next

Return to Audio Plugins

Who is online

Users browsing this forum: No registered users and 3 guests