COCKOS
CONFEDERATED FORUMS
Cockos : REAPER : NINJAM : Forums
Forum Home : Register : FAQ : Members List : Search :
Old 11-03-2010, 07:58 PM   #81
sstillwell
Human being with feelings
 
Join Date: Jul 2006
Location: Cowtown
Posts: 1,562
Default

Quote:
Originally Posted by Tale View Post
Using your IPlugAU.r my plug-in now also crashes, so at least it gets recognized.

EDIT: My 64-bit plug-in crashes in IPlugAU::IPlugAUEntry(), case kAudioUnitGetPropertyInfoSelect, when it tries to execute *pWriteable = false.
Look at this snippet from AUDispatch.cpp...part of Apple's AU class hierarchy...

Code:
	#if __LP64__
		// comp instance, parameters in forward order
		#define PARAM(_typ, _name, _index, _nparams) \
			_typ _name = *(_typ *)&params->params[_index + 1];
	#else
		// parameters in reverse order, then comp instance
		#define PARAM(_typ, _name, _index, _nparams) \
			_typ _name = *(_typ *)&params->params[_nparams - 1 - _index];
	#endif
And then look at the definition of GET_COMP_PARAM in IPlugAU.cpp. Why on earth would they reverse the order of everything on 64-bit platforms? It's not (or shouldn't be) an endian thing...

I suspect this is a good part of why it's crashing...but I could of course be wrong.

My brain hurts.

Scott
__________________
https://www.stillwellaudio.com/
sstillwell is offline   Reply With Quote
Old 11-04-2010, 09:31 AM   #82
Tale
Human being with feelings
 
Tale's Avatar
 
Join Date: Jul 2008
Location: The Netherlands
Posts: 3,645
Default

Quote:
Originally Posted by sstillwell View Post
I suspect this is a good part of why it's crashing...but I could of course be wrong.
Yes, that's it, you've cracked the case! I now have a hacked x64 AU version of ComboV running on REAPER x64.


Quote:
Originally Posted by sstillwell View Post
My brain hurts.
No, no, no, my brain in my head. ... It will have to come out.
Tale is offline   Reply With Quote
Old 11-04-2010, 10:14 AM   #83
sstillwell
Human being with feelings
 
Join Date: Jul 2006
Location: Cowtown
Posts: 1,562
Default

Quote:
Originally Posted by Tale View Post
Yes, that's it, you've cracked the case! I now have a hacked x64 AU version of ComboV running on REAPER x64.
VERY cool. How did you wind up doing that to make it compatible across 32/64 bit? Macro changes like Apple does, or did you just #ifdef the whole section of code and reverse the index numbers?

Scott
__________________
https://www.stillwellaudio.com/
sstillwell is offline   Reply With Quote
Old 11-04-2010, 02:07 PM   #84
Tale
Human being with feelings
 
Tale's Avatar
 
Join Date: Jul 2008
Location: The Netherlands
Posts: 3,645
Default

Quote:
Originally Posted by sstillwell View Post
How did you wind up doing that to make it compatible across 32/64 bit? Macro changes like Apple does, or did you just #ifdef the whole section of code and reverse the index numbers?
I used a variation on Apple's macro:

Code:
#if __LP64__
	#define GET_COMP_PARAM(TYPE, IDX, NUM) *((TYPE*)&(params->params[NUM - IDX]))
#else
	#define GET_COMP_PARAM(TYPE, IDX, NUM) *((TYPE*)&(params->params[IDX]))
#endif
And then:

Code:
    case kAudioUnitGetPropertyInfoSelect: {
      AudioUnitPropertyID propID = GET_COMP_PARAM(AudioUnitPropertyID, 4, 5);
      AudioUnitScope scope = GET_COMP_PARAM(AudioUnitScope, 3, 5);
      AudioUnitElement element = GET_COMP_PARAM(AudioUnitElement, 2, 5);
      UInt32* pDataSize = GET_COMP_PARAM(UInt32*, 1, 5);
      Boolean* pWriteable = GET_COMP_PARAM(Boolean*, 0, 5);
Etc. etc.
Tale is offline   Reply With Quote
Old 11-04-2010, 07:57 PM   #85
sstillwell
Human being with feelings
 
Join Date: Jul 2006
Location: Cowtown
Posts: 1,562
Default

Right on! Working here, as well. Don't have a G5 to test PPC64 against, but I'll bet that's fine too.

Yay us.

Scott
__________________
https://www.stillwellaudio.com/
sstillwell is offline   Reply With Quote
Old 11-06-2010, 02:54 AM   #86
Tale
Human being with feelings
 
Tale's Avatar
 
Join Date: Jul 2008
Location: The Netherlands
Posts: 3,645
Default

Quote:
Originally Posted by sstillwell View Post
Don't have a G5 to test PPC64 against, but I'll bet that's fine too.
Do you think there are a lot of PPC64 Macs out there? I was thinking of keeping my current PPC/Intel 32-bit OS X 10.0.4 build, and add an OS X 10.0.5 Intel 32/64-bit build with no PPC support.

BTW, I have found a couple of issues with IPlugAU.r (#ifdef where it should read #if, won't build for just 1 platform), and I have added more dual "fat" combinations. My Git repository contains an updated version.
Tale is offline   Reply With Quote
Old 11-07-2010, 12:17 AM   #87
sstillwell
Human being with feelings
 
Join Date: Jul 2006
Location: Cowtown
Posts: 1,562
Default

Quote:
Originally Posted by Tale View Post
Do you think there are a lot of PPC64 Macs out there? I was thinking of keeping my current PPC/Intel 32-bit OS X 10.0.4 build, and add an OS X 10.0.5 Intel 32/64-bit build with no PPC support.

BTW, I have found a couple of issues with IPlugAU.r (#ifdef where it should read #if, won't build for just 1 platform), and I have added more dual "fat" combinations. My Git repository contains an updated version.
Any G5 processor is 64-bit, and parts of the OS and libraries have been 64-bit enabled since 10.2-ish. Otherwise there would be no point in G5s with 8 GB of RAM, which weren't that uncommon.

I've got some of my plugs up and running now on x64...yay! Lots of work remaining, but forward motion is...err...going forward!

Scott
__________________
https://www.stillwellaudio.com/
sstillwell is offline   Reply With Quote
Old 11-22-2010, 01:23 AM   #88
RRokkenAudio
Human being with feelings
 
RRokkenAudio's Avatar
 
Join Date: Jun 2009
Location: Buffalo, NY
Posts: 777
Default

What do you need to do, to host your git on your page. Can't find any info...Hopefully i don't need a dedicated host just for git heh.
RRokkenAudio is offline   Reply With Quote
Old 11-22-2010, 01:36 AM   #89
Tale
Human being with feelings
 
Tale's Avatar
 
Join Date: Jul 2008
Location: The Netherlands
Posts: 3,645
Default

I run the following commands to create a "bare" repository in a directory called WDL.git:

Code:
git clone --bare . WDL.git
cd WDL.git
git --bare update-server-info
I then upload the WDL.git directory to my webserver using FTP (in binary file mode).
Tale is offline   Reply With Quote
Old 11-22-2010, 01:50 AM   #90
bvesco
Human being with feelings
 
bvesco's Avatar
 
Join Date: Jun 2007
Posts: 125
Default

Quote:
Originally Posted by RRokkenAudio View Post
What do you need to do, to host your git on your page. Can't find any info...Hopefully i don't need a dedicated host just for git heh.
You can use github for a free online repo that is already git-ified.
__________________
Audio tutorials and articles: http://www.benvesco.com/tonemonster/
My VST plugins: http://www.vescofx.com/
bvesco is offline   Reply With Quote
Old 11-22-2010, 08:20 AM   #91
sstillwell
Human being with feelings
 
Join Date: Jul 2006
Location: Cowtown
Posts: 1,562
Default

Quote:
Originally Posted by bvesco View Post
You can use github for a free online repo that is already git-ified.
Only if the project is going to be open-source. I know, you generally wouldn't have it on a publicly accessible server if it WASN'T open-source, but it's worth clarifying.

Github has paid plans that allow closed-source repositories, but to qualify for free hosting it has to be open-source.

Scott
__________________
https://www.stillwellaudio.com/
sstillwell is offline   Reply With Quote
Old 11-23-2010, 10:04 AM   #92
bvesco
Human being with feelings
 
bvesco's Avatar
 
Join Date: Jun 2007
Posts: 125
Default

@Scott

Yes, only if the project is open source. I believe Rob's goal was to find hosting for his personal modifications to WDL and IPlug to be shared with the community here, not for hosting the source code of his plugins. With that in mind Github is still an appropriate solution because Rob can keep his WDL mods public and open source while hosting his actual plugin code elsewhere.
__________________
Audio tutorials and articles: http://www.benvesco.com/tonemonster/
My VST plugins: http://www.vescofx.com/
bvesco is offline   Reply With Quote
Old 12-17-2010, 11:22 AM   #93
olilarkin
Human being with feelings
 
Join Date: Apr 2009
Location: Berlin, Germany
Posts: 1,248
Default

i finally got around to using git. one thing i'm not sure of is if i should have a WDL.git or just a .git

Are you guys renaming the .git directory when you upload it?

thanks,

oli
__________________
VirtualCZ | Endless Series | iPlug2 | Linkedin | Facebook
olilarkin is offline   Reply With Quote
Old 12-17-2010, 11:56 AM   #94
Tale
Human being with feelings
 
Tale's Avatar
 
Join Date: Jul 2008
Location: The Netherlands
Posts: 3,645
Default

Actually I clone my Git repository to a bare repository already called WDL.git, and then I upload this bare repository, see here and/or here.
Tale is offline   Reply With Quote
Old 12-17-2010, 12:08 PM   #95
olilarkin
Human being with feelings
 
Join Date: Apr 2009
Location: Berlin, Germany
Posts: 1,248
Default

cool, got it.

here is my one http://www.olilarkin.co.uk/dev/WDL.git/

oli
__________________
VirtualCZ | Endless Series | iPlug2 | Linkedin | Facebook
olilarkin is offline   Reply With Quote
Old 12-18-2010, 04:35 PM   #96
olilarkin
Human being with feelings
 
Join Date: Apr 2009
Location: Berlin, Germany
Posts: 1,248
Default

if anyone's interested i just uploaded a new version with a template project and duplication script that i use to rapidly set up new projects. It copies the template folder and does a multi-file find and replace (in file names and class names). It builds for win32 and x64 (although i didn't test the x64 binaries yet). Next i'll add the 64bit au support.

The template has some useful debugging stuff set up already.

Note: both the visual studio project and xcode project are not building the static library, they just include all the necessary iplug sources

note #2: the duplicator script only works on osx at the moment
__________________
VirtualCZ | Endless Series | iPlug2 | Linkedin | Facebook
olilarkin is offline   Reply With Quote
Old 06-24-2011, 04:23 AM   #97
Tale
Human being with feelings
 
Tale's Avatar
 
Join Date: Jul 2008
Location: The Netherlands
Posts: 3,645
Default Updated zlib and libpng

The zlib and libpng versions that come with Cockos WDL are a bit outdated. This is not necessarily a bad thing (don't fix what isn't broken?), but I nevertheless have updated both libs to the latest stable versions. If anyone wants to cherry-pick these updates, here are the two commits in my Git repository:
  • 5af40e7 zlib: Updated to v1.2.5.
  • 98b845f libpng: Updated to v1.5.2.

If you do cherry-pick these, then you will probably have to do some minor changes to your project files (see the full descriptions for both commits).
Tale is offline   Reply With Quote
Old 01-08-2012, 01:51 PM   #98
Justin
Administrator
 
Justin's Avatar
 
Join Date: Jan 2005
Location: NYC
Posts: 15,716
Default

Quote:
Originally Posted by Tale View Post
The zlib and libpng versions that come with Cockos WDL are a bit outdated. This is not necessarily a bad thing (don't fix what isn't broken?), but I nevertheless have updated both libs to the latest stable versions. If anyone wants to cherry-pick these updates, here are the two commits in my Git repository:
  • 5af40e7 zlib: Updated to v1.2.5.
  • 98b845f libpng: Updated to v1.5.2.

If you do cherry-pick these, then you will probably have to do some minor changes to your project files (see the full descriptions for both commits).
Just pushed updates to the main Cockos WDL repos, including the new libpng above (though we still use old 1.2.3 zlib, I think)... Thanks, Tale!
Justin is offline   Reply With Quote
Old 01-08-2012, 03:33 PM   #99
Tranquil
Human being with feelings
 
Join Date: Feb 2005
Location: Greece
Posts: 100
Default

Quote:
Originally Posted by Justin View Post
Just pushed updates to the main Cockos WDL repos, including the new libpng above (though we still use old 1.2.3 zlib, I think)... Thanks, Tale!
Is there a particular technical reason not to update to zlib 1.2.5 or it's just the result of boredom?

also changed pngstruct.h include
Code:
diff --git a/source/WDL/libpng/pngstruct.h b/source/WDL/libpng/pngstruct.h
index 33f2384..5780901 100644
--- a/source/WDL/libpng/pngstruct.h
+++ b/source/WDL/libpng/pngstruct.h
@@ -24,7 +24,7 @@
  * in this structure and is required for decompressing the LZ compressed
  * data in PNG files.
  */
-#include "zlib.h"
+#include "../zlib/zlib.h"

 struct png_struct_def
 {
Tranquil is offline   Reply With Quote
Old 01-09-2012, 01:46 AM   #100
Tale
Human being with feelings
 
Tale's Avatar
 
Join Date: Jul 2008
Location: The Netherlands
Posts: 3,645
Default

Quote:
Originally Posted by Justin View Post
Just pushed updates to the main Cockos WDL repos, including the new libpng above (though we still use old 1.2.3 zlib, I think)... Thanks, Tale!
You are welcome, and thank you for updating WDL.

BTW, my post above was about libpng v1.5.2, but since I have updated it to v1.5.6, which is also included in the updated Cockos WDL.

Quote:
Originally Posted by Tranquil View Post
-#include "zlib.h"
+#include "../zlib/zlib.h"
Alternatively you could tell you compiler to look for include files in ../zlib.
Tale is offline   Reply With Quote
Old 01-09-2012, 11:48 AM   #101
Justin
Administrator
 
Justin's Avatar
 
Join Date: Jan 2005
Location: NYC
Posts: 15,716
Default

Ooops I lied, we are on 1.5.6 as well. Though neat 1.5.7 is out.
Justin is offline   Reply With Quote
Old 01-09-2012, 03:29 PM   #102
Tale
Human being with feelings
 
Tale's Avatar
 
Join Date: Jul 2008
Location: The Netherlands
Posts: 3,645
Default

Quote:
Originally Posted by Justin View Post
Though neat 1.5.7 is out.
It's already hard just to keep up with you sometimes, let alone stay ahead of you... But here you go: I have updated to libpng v1.5.7 (commit c091f24 in my WDL edition).
Tale is offline   Reply With Quote
Old 02-10-2012, 03:57 PM   #103
Tale
Human being with feelings
 
Tale's Avatar
 
Join Date: Jul 2008
Location: The Netherlands
Posts: 3,645
Default Updated libpng to v1.5.8 (fixes security issue)

I have just updated libpng to v1.5.8 (see commit d31310c), which includes a fix for a buffer-overrun vulnerability in v1.5.7.
Tale is offline   Reply With Quote
Old 03-06-2012, 05:58 AM   #104
Tale
Human being with feelings
 
Tale's Avatar
 
Join Date: Jul 2008
Location: The Netherlands
Posts: 3,645
Default Updated to libpng v1.5.9

Yup, another vulnerability fix in libpng, so I have updated to v1.5.9 (commit 79e5edc7fa in my repository).
Tale is offline   Reply With Quote
Old 05-08-2012, 04:03 AM   #105
Tale
Human being with feelings
 
Tale's Avatar
 
Join Date: Jul 2008
Location: The Netherlands
Posts: 3,645
Default Updated to libpng v1.5.10, zlib v1.2.7

FYI: I have updated my WDL's libpng to v1.5.10, and zlib to v1.2.7.
Tale is offline   Reply With Quote
Old 10-20-2014, 09:56 AM   #106
Argitoth
Human being with feelings
 
Argitoth's Avatar
 
Join Date: Feb 2008
Location: Mesa, AZ
Posts: 2,057
Default

There is 'k' and 'm' at the beginning of many variables. What do they represent?
__________________
Soundemote - Home of the chaosfly and pretty oscilloscope.
MyReaperPlugin - Easy-to-use cross-platform C++ REAPER extension template
Argitoth is offline   Reply With Quote
Old 10-20-2014, 10:13 AM   #107
Tale
Human being with feelings
 
Tale's Avatar
 
Join Date: Jul 2008
Location: The Netherlands
Posts: 3,645
Default

Quote:
Originally Posted by Argitoth View Post
There is 'k' and 'm' at the beginning of many variables. What do they represent?
The m for member variable, the k for constant (I think). Sometimes you will also see g for global, s for static, and e for enumerator. These prefixes are used to distinguish beteen normal (local) variables, and member/global/static variables or constants/enumerators. Note that you don't have to use these prefixes, but it is considered good practice.

Code:
class MyClass
{
	...

	int mY;

	void Square(int x)
	{
		int y = x*x;
		mY = y;
	}
};
Tale is offline   Reply With Quote
Old 10-20-2014, 10:14 AM   #108
sstillwell
Human being with feelings
 
Join Date: Jul 2006
Location: Cowtown
Posts: 1,562
Default

Quote:
Originally Posted by Argitoth View Post
There is 'k' and 'm' at the beginning of many variables. What do they represent?
'k' usually represents a (k)onstant, and 'm' is usually a (m)ember variable in a class.

Scott
__________________
https://www.stillwellaudio.com/
sstillwell is offline   Reply With Quote
Old 10-20-2014, 10:15 AM   #109
Argitoth
Human being with feelings
 
Argitoth's Avatar
 
Join Date: Feb 2008
Location: Mesa, AZ
Posts: 2,057
Default

two replies for the price of 1, thanks!
__________________
Soundemote - Home of the chaosfly and pretty oscilloscope.
MyReaperPlugin - Easy-to-use cross-platform C++ REAPER extension template
Argitoth is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -7. The time now is 02:01 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.