On Sep 21, 2016, at 3:40 PM, pd-list-request@lists.iem.at wrote:
From: Antoine Rousseau <antoine@metalu.net mailto:antoine@metalu.net>
Thanks ! and thanks to Dan too, pointing me directly to the right direction ! But I realize that if I fix mknob for latest Pd it will become incompatible with older ones…
I believe the changes handle saving and loading based on the compatibility mode, so you should be able to simply check the version and call that iem color function in versions of pd less than 0.48.
Dan Wilcox @danomatika https://twitter.com/danomatika danomatika.com http://danomatika.com/ robotcowboy.com http://robotcowboy.com/
to simply check the version and call that iem color function
I don't think so ; the interface of some functions has changed, so you need to be aware of the version at compilation time, and have to use this version at runtime. So I don't think you can build an external that would be compatible for both versions.
2016-09-22 0:22 GMT+02:00 Dan Wilcox danomatika@gmail.com:
On Sep 21, 2016, at 3:40 PM, pd-list-request@lists.iem.at wrote:
*From: *Antoine Rousseau antoine@metalu.net
Thanks ! and thanks to Dan too, pointing me directly to the right direction ! But I realize that if I fix mknob for latest Pd it will become incompatible with older ones…
I believe the changes handle saving and loading based on the compatibility mode, so you should be able to simply check the version and call that iem color function in versions of pd less than 0.48.
Dan Wilcox @danomatika https://twitter.com/danomatika danomatika.com robotcowboy.com
you're right, but with some #ifdefs, at least the source can be compatible with both versions. building from source will then always work. regarding binaries and deken packages, you would have to do it twice, though. Maybe just give a little hint in the name? (>= Pd.047 resp. < Pd 0.47). Anyway, if you need testing on Windows (for both versions of Pd), count me in!
Gesendet: Donnerstag, 22. September 2016 um 08:37 Uhr Von: "Antoine Rousseau" antoine@metalu.net An: "Dan Wilcox" danomatika@gmail.com Cc: Pd-list pd-list@lists.iem.at Betreff: Re: [PD] Tcl error for [knob] and [mknob]
to simply check the version and call that iem color function I don't think so ; the interface of some functions has changed, so you need to be aware of the version at compilation time, and have to use this version at runtime. So I don't think you can build an external that would be compatible for both versions. 2016-09-22 0:22 GMT+02:00 Dan Wilcox danomatika@gmail.com:
On Sep 21, 2016, at 3:40 PM, pd-list-request@lists.iem.at[pd-list-request@lists.iem.at] wrote:
From: Antoine Rousseau <antoine@metalu.net[antoine@metalu.net]>
Thanks ! and thanks to Dan too, pointing me directly to the right direction !But I realize that if I fix mknob for latest Pd it will become incompatible with older ones…I believe the changes handle saving and loading based on the compatibility mode, so you should be able to simply check the version and call that iem color function in versions of pd less than 0.48.
Dan Wilcox @danomatika[https://twitter.com/danomatika] danomatika.com[http://danomatika.com] robotcowboy.com[http://robotcowboy.com]
--
Antoine Rousseau http://www.metalu.net%5Bhttp://metalu.net%5D%C2%A0__%C2%A0http://www.metalua...] _______________________________________________ Pd-list@lists.iem.at mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/listinfo/pd-list%5Bhttps://lists.puredata.info/l...]
On 2016-09-22 08:37, Antoine Rousseau wrote:
you need to be aware of the version at compilation time, and have to use this version at runtime. So I don't think you can build an external that would be compatible for both versions.
why?
amsdr IOhannes
2016-09-22 11:03 GMT+02:00 IOhannes m zmoelnig zmoelnig@iem.at:
On 2016-09-22 08:37, Antoine Rousseau wrote:
you need to be aware of the version at compilation time, and have to use this version at runtime. So I don't think you can build an external that would be compatible for both versions.
why?
Because interfaces changed :
-void iemgui_save(t_iemgui *iemgui, t_symbol **srl, int *bflcol) +void iemgui_save(t_iemgui *iemgui, t_symbol **srl, t_symbol**bflcol)
(from https://github.com/pure-data/pure-data/commit/6af3739b2284cfd53ad0ca8eeb2d3c... )
so how could I build a binary that would switch the interface of iemgui_save at runtime, following the version of the running Pd ?
On 2016-09-22 12:21, Antoine Rousseau wrote:
2016-09-22 11:03 GMT+02:00 IOhannes m zmoelnig zmoelnig@iem.at:
On 2016-09-22 08:37, Antoine Rousseau wrote:
you need to be aware of the version at compilation time, and have to use this version at runtime. So I don't think you can build an external that would be compatible for both versions.
why?
Because interfaces changed :
-void iemgui_save(t_iemgui *iemgui, t_symbol **srl, int *bflcol) +void iemgui_save(t_iemgui *iemgui, t_symbol **srl, t_symbol**bflcol)
[...]
so how could I build a binary that would switch the interface of iemgui_save at runtime, following the version of the running Pd ?
in pseudo code: if(pd<0.47) iemgui_save(x, srl, i_color); else iemgui_save(x, srl, s_color);
this will give you some compiler warnings, but you can do:
typedef void(t_iemgui_save_old*)(t_iemgui *iemgui, t_symbol **srl, int *bflcol); typedef void(t_iemgui_save_new*)(t_iemgui *iemgui, t_symbol **srl, t_symbol **bflcol);
if(pd<0.47) { t_iemgui_save_old isave=(t_iemgui_save_old)iemgui_save; isave(x, srl, i_color); } else { t_iemgui_save_old isave=(t_iemgui_save_new)iemgui_save; isave(x, srl, s_color); }
fgmsdr IOhannes
Thanks a lot ! I think I get it. I'll do it asap.
2016-09-22 17:06 GMT+02:00 IOhannes m zmoelnig zmoelnig@iem.at:
On 2016-09-22 12:21, Antoine Rousseau wrote:
2016-09-22 11:03 GMT+02:00 IOhannes m zmoelnig zmoelnig@iem.at:
On 2016-09-22 08:37, Antoine Rousseau wrote:
you need to be aware of the version at compilation time, and have to use this version at runtime. So I don't think you can build an external that
would
be compatible for both versions.
why?
Because interfaces changed :
-void iemgui_save(t_iemgui *iemgui, t_symbol **srl, int *bflcol) +void iemgui_save(t_iemgui *iemgui, t_symbol **srl, t_symbol**bflcol)
[...]
so how could I build a binary that would switch the interface of
iemgui_save
at runtime, following the version of the running Pd ?
in pseudo code: if(pd<0.47) iemgui_save(x, srl, i_color); else iemgui_save(x, srl, s_color);
this will give you some compiler warnings, but you can do:
typedef void(t_iemgui_save_old*)(t_iemgui *iemgui, t_symbol **srl, int *bflcol); typedef void(t_iemgui_save_new*)(t_iemgui *iemgui, t_symbol **srl, t_symbol **bflcol);
if(pd<0.47) { t_iemgui_save_old isave=(t_iemgui_save_old)iemgui_save; isave(x, srl, i_color); } else { t_iemgui_save_old isave=(t_iemgui_save_new)iemgui_save; isave(x, srl, s_color); }
fgmsdr IOhannes
Pd-list@lists.iem.at mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/ listinfo/pd-list
Sorry, if I'm being obvious: I found 'sys_getversion' at the end of m_glob.c which returns major and minor version number at runtime. Christof
Gesendet: Donnerstag, 22. September 2016 um 17:56 Uhr Von: "Antoine Rousseau" antoine@metalu.net An: Kein Empfänger Cc: Pd-list pd-list@lists.iem.at Betreff: Re: [PD] Tcl error for [knob] and [mknob]
Thanks a lot ! I think I get it. I'll do it asap. 2016-09-22 17:06 GMT+02:00 IOhannes m zmoelnig zmoelnig@iem.at:On 2016-09-22 12:21, Antoine Rousseau wrote:
2016-09-22 11:03 GMT+02:00 IOhannes m zmoelnig <zmoelnig@iem.at[zmoelnig@iem.at]>:
On 2016-09-22 08:37, Antoine Rousseau wrote:
you need to be aware of the version at compilation time, and have to use this version at runtime. So I don't think you can build an external that would be compatible for both versions.
why?
Because interfaces changed :
-void iemgui_save(t_iemgui *iemgui, t_symbol **srl, int *bflcol) +void iemgui_save(t_iemgui *iemgui, t_symbol **srl, t_symbol**bflcol)
[...]
so how could I build a binary that would switch the interface of iemgui_save at runtime, following the version of the running Pd ?
in pseudo code: if(pd<0.47) iemgui_save(x, srl, i_color); else iemgui_save(x, srl, s_color);
this will give you some compiler warnings, but you can do:
typedef void(t_iemgui_save_old*)(t_iemgui *iemgui, t_symbol **srl, int *bflcol); typedef void(t_iemgui_save_new*)(t_iemgui *iemgui, t_symbol **srl, t_symbol **bflcol);
if(pd<0.47) { t_iemgui_save_old isave=(t_iemgui_save_old)iemgui_save; isave(x, srl, i_color); } else { t_iemgui_save_old isave=(t_iemgui_save_new)iemgui_save; isave(x, srl, s_color); }
fgmsdr IOhannes
Pd-list@lists.iem.at[Pd-list@lists.iem.at] mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/listinfo/pd-list%5Bhttps://lists.puredata.info/l...]
--
Antoine Rousseau http://www.metalu.net%5Bhttp://metalu.net%5D%C2%A0__%C2%A0http://www.metalua...] _______________________________________________ Pd-list@lists.iem.at mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/listinfo/pd-list%5Bhttps://lists.puredata.info/l...]
Hi all
in order to try making a mknob that would be compatible with any Pd version, I still have a problem, with a function that didn't exist prior to 0.47 (iemgui_all_loadcolors). Would someone have an idea to "hide" the call of this function when linked by an older version of Pd?
Anyway I now have a version of mknob that is working with 0.47. I'll push it soon.
2016-09-24 5:16 GMT+02:00 Billy Stiltner billy.stiltner@gmail.com:
while on the subject subject of knobs, would be great to hav option for
integer snapping
its easy to do with a few objects in a patch
Pd-list@lists.iem.at mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/li stinfo/pd-list
Hello,
why not using preprocessor expression like
#if PD_MINOR_VERSION < 47
... iemgui_all_loadcolors();
...
#endif
?
Le 25/09/2016 à 16:25, Antoine Rousseau a écrit :
Hi all
in order to try making a mknob that would be compatible with any Pd version, I still have a problem, with a function that didn't exist prior to 0.47 (iemgui_all_loadcolors). Would someone have an idea to "hide" the call of this function when linked by an older version of Pd?
Anyway I now have a version of mknob that is working with 0.47. I'll push it soon.
2016-09-24 5:16 GMT+02:00 Billy Stiltner <billy.stiltner@gmail.com mailto:billy.stiltner@gmail.com>:
while on the subject subject of knobs, would be great to hav option for integer snapping its easy to do with a few objects in a patch _______________________________________________ Pd-list@lists.iem.at <mailto:Pd-list@lists.iem.at> mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/listinfo/pd-list <https://lists.puredata.info/listinfo/pd-list>
-- Antoine Rousseau http://www.metalu.net http://metalu.net __ http://www.metaluachahuter.com/ http://www.metaluachahuter.com/compagnies/al1-ant1/
Pd-list@lists.iem.at mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/listinfo/pd-list
Because in his case, the pd version is only known at runtime.
Gesendet: Sonntag, 25. September 2016 um 19:21 Uhr Von: "patrice colet" colet.patrice@free.fr An: pd-list@lists.iem.at Betreff: Re: [PD] Tcl error for [knob] and [mknob]
Hello,
why not using preprocessor expression like
#if PD_MINOR_VERSION < 47
... iemgui_all_loadcolors();
...
#endif
?
Le 25/09/2016 à 16:25, Antoine Rousseau a écrit :
Hi all
in order to try making a mknob that would be compatible with any Pd version, I still have a problem, with a function that didn't exist prior to 0.47 (iemgui_all_loadcolors). Would someone have an idea to "hide" the call of this function when linked by an older version of Pd?
Anyway I now have a version of mknob that is working with 0.47. I'll push it soon.
2016-09-24 5:16 GMT+02:00 Billy Stiltner <billy.stiltner@gmail.com mailto:billy.stiltner@gmail.com>:
while on the subject subject of knobs, would be great to hav option for integer snapping its easy to do with a few objects in a patch _______________________________________________ Pd-list@lists.iem.at <mailto:Pd-list@lists.iem.at> mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/listinfo/pd-list <https://lists.puredata.info/listinfo/pd-list>
-- Antoine Rousseau http://www.metalu.net http://metalu.net __ http://www.metaluachahuter.com/ http://www.metaluachahuter.com/compagnies/al1-ant1/
Pd-list@lists.iem.at mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/listinfo/pd-list
-- Patrice Colet fr: 0632660357
Pd-list@lists.iem.at mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/listinfo/pd-list
Thanks for the answer, I see know how it's happening, so maybe this could be resolved with the linker like explained in following URL:
http://stackoverflow.com/questions/1617286/easy-check-for-unresolved-symbols...
just removing -z option at compile time would do the trick?
Le 25/09/2016 à 20:02, Christof Ressi a écrit :
Because in his case, the pd version is only known at runtime.
Gesendet: Sonntag, 25. September 2016 um 19:21 Uhr Von: "patrice colet" colet.patrice@free.fr An: pd-list@lists.iem.at Betreff: Re: [PD] Tcl error for [knob] and [mknob]
Hello,
why not using preprocessor expression like
#if PD_MINOR_VERSION < 47
... iemgui_all_loadcolors();
...
#endif
?
Le 25/09/2016 à 16:25, Antoine Rousseau a écrit :
Hi all
in order to try making a mknob that would be compatible with any Pd version, I still have a problem, with a function that didn't exist prior to 0.47 (iemgui_all_loadcolors). Would someone have an idea to "hide" the call of this function when linked by an older version of Pd?
Anyway I now have a version of mknob that is working with 0.47. I'll push it soon.
2016-09-24 5:16 GMT+02:00 Billy Stiltner <billy.stiltner@gmail.com mailto:billy.stiltner@gmail.com>:
while on the subject subject of knobs, would be great to hav option for integer snapping its easy to do with a few objects in a patch _______________________________________________ Pd-list@lists.iem.at <mailto:Pd-list@lists.iem.at> mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/listinfo/pd-list <https://lists.puredata.info/listinfo/pd-list>
-- Antoine Rousseau http://www.metalu.net http://metalu.net __ http://www.metaluachahuter.com/ http://www.metaluachahuter.com/compagnies/al1-ant1/
Pd-list@lists.iem.at mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/listinfo/pd-list
-- Patrice Colet fr: 0632660357
Pd-list@lists.iem.at mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/listinfo/pd-list
the pd version is only known at runtime.
yes that's the point. I'm looking for a kind of dlsym() working for already loaded symbols.
2016-09-25 20:02 GMT+02:00 Christof Ressi christof.ressi@gmx.at:
Because in his case, the pd version is only known at runtime.
Gesendet: Sonntag, 25. September 2016 um 19:21 Uhr Von: "patrice colet" colet.patrice@free.fr An: pd-list@lists.iem.at Betreff: Re: [PD] Tcl error for [knob] and [mknob]
Hello,
why not using preprocessor expression like
#if PD_MINOR_VERSION < 47
... iemgui_all_loadcolors();
...
#endif
?
Le 25/09/2016 à 16:25, Antoine Rousseau a écrit :
Hi all
in order to try making a mknob that would be compatible with any Pd version, I still have a problem, with a function that didn't exist prior to 0.47 (iemgui_all_loadcolors). Would someone have an idea to "hide" the call of this function when linked by an older version of Pd?
Anyway I now have a version of mknob that is working with 0.47. I'll push it soon.
2016-09-24 5:16 GMT+02:00 Billy Stiltner <billy.stiltner@gmail.com mailto:billy.stiltner@gmail.com>:
while on the subject subject of knobs, would be great to hav option for integer snapping its easy to do with a few objects in a patch _______________________________________________ Pd-list@lists.iem.at <mailto:Pd-list@lists.iem.at> mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/listinfo/pd-list <https://lists.puredata.info/listinfo/pd-list>
-- Antoine Rousseau http://www.metalu.net http://metalu.net __ http://www.metaluachahuter.com/ http://www.metaluachahuter.com/compagnies/al1-ant1/
Pd-list@lists.iem.at mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/
listinfo/pd-list
-- Patrice Colet fr: 0632660357
Pd-list@lists.iem.at mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/
listinfo/pd-list
Pd-list@lists.iem.at mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/ listinfo/pd-list
ok, seems resolved now ! But I had to use some tricks about dynamic symbol resolution, that should be tested on windows. Any volunteer ?.. ( https://github.com/MetaluNet/moonlib)
2016-09-25 21:13 GMT+02:00 Antoine Rousseau antoine@metalu.net:
the pd version is only known at runtime.
yes that's the point. I'm looking for a kind of dlsym() working for already loaded symbols.
2016-09-25 20:02 GMT+02:00 Christof Ressi christof.ressi@gmx.at:
Because in his case, the pd version is only known at runtime.
Gesendet: Sonntag, 25. September 2016 um 19:21 Uhr Von: "patrice colet" colet.patrice@free.fr An: pd-list@lists.iem.at Betreff: Re: [PD] Tcl error for [knob] and [mknob]
Hello,
why not using preprocessor expression like
#if PD_MINOR_VERSION < 47
... iemgui_all_loadcolors();
...
#endif
?
Le 25/09/2016 à 16:25, Antoine Rousseau a écrit :
Hi all
in order to try making a mknob that would be compatible with any Pd version, I still have a problem, with a function that didn't exist prior to 0.47 (iemgui_all_loadcolors). Would someone have an idea to "hide" the call of this function when linked by an older version of
Pd?
Anyway I now have a version of mknob that is working with 0.47. I'll push it soon.
2016-09-24 5:16 GMT+02:00 Billy Stiltner <billy.stiltner@gmail.com mailto:billy.stiltner@gmail.com>:
while on the subject subject of knobs, would be great to hav option for integer snapping its easy to do with a few objects in a patch _______________________________________________ Pd-list@lists.iem.at <mailto:Pd-list@lists.iem.at> mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/listinfo/pd-list <https://lists.puredata.info/listinfo/pd-list>
-- Antoine Rousseau http://www.metalu.net http://metalu.net __ http://www.metaluachahuter.com/ http://www.metaluachahuter.com/compagnies/al1-ant1/
Pd-list@lists.iem.at mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/li
stinfo/pd-list
-- Patrice Colet fr: 0632660357
Pd-list@lists.iem.at mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/li
stinfo/pd-list
Pd-list@lists.iem.at mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/li stinfo/pd-list
-- Antoine Rousseau http://www.metalu.net http://metalu.net __ htt p://www.metaluachahuter.com/ http://www.metaluachahuter.com/compagnies/al1-ant1/
Thanks for your efforts! I'm willing to test and I've already tried to compile but got a few errors. I posted the results on your repository (spacechild1). Let's continue there.
Christof
Gesendet: Montag, 26. September 2016 um 00:16 Uhr Von: "Antoine Rousseau" antoine@metalu.net An: pd-list pd-list@iem.at Betreff: Re: [PD] Tcl error for [knob] and [mknob]
ok, seems resolved now !But I had to use some tricks about dynamic symbol resolution, that should be tested on windows. Any volunteer ?.. (https://github.com/MetaluNet/moonlib)
2016-09-25 21:13 GMT+02:00 Antoine Rousseau <antoine@metalu.net[antoine@metalu.net]>: the pd version is only known at runtime.yes that's the point. I'm looking for a kind of dlsym() working for already loaded symbols.
2016-09-25 20:02 GMT+02:00 Christof Ressi <christof.ressi@gmx.at[christof.ressi@gmx.at]>:Because in his case, the pd version is only known at runtime.
Gesendet: Sonntag, 25. September 2016 um 19:21 Uhr Von: "patrice colet" <colet.patrice@free.fr[colet.patrice@free.fr]> An: pd-list@lists.iem.at[pd-list@lists.iem.at] Betreff: Re: [PD] Tcl error for [knob] and [mknob]
Hello,
why not using preprocessor expression like
#if PD_MINOR_VERSION < 47
... iemgui_all_loadcolors();
...
#endif
?
Le 25/09/2016 à 16:25, Antoine Rousseau a écrit :
Hi all
in order to try making a mknob that would be compatible with any Pd version, I still have a problem, with a function that didn't exist prior to 0.47 (iemgui_all_loadcolors). Would someone have an idea to "hide" the call of this function when linked by an older version of Pd?
Anyway I now have a version of mknob that is working with 0.47. I'll push it soon.
2016-09-24 5:16 GMT+02:00 Billy Stiltner <billy.stiltner@gmail.com[billy.stiltner@gmail.com] mailto:billy.stiltner@gmail.com[billy.stiltner@gmail.com]>:
while on the subject subject of knobs, would be great to hav option for integer snapping
its easy to do with a few objects in a patch
_______________________________________________ Pd-list@lists.iem.at[Pd-list@lists.iem.at] mailto:Pd-list@lists.iem.at[Pd-list@lists.iem.at] mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/listinfo/pd-list%5Bhttps://lists.puredata.info/l...] https://lists.puredata.info/listinfo/pd-list[https://lists.puredata.info/listinfo/pd-list]
-- Antoine Rousseau http://www.metalu.net%5Bhttp://www.metalu.net] http://metalu.net[http://metalu.net] __ http://www.metaluachahuter.com/%5Bhttp://www.metaluachahuter.com/] http://www.metaluachahuter.com/compagnies/al1-ant1/[http://www.metaluachahuter.com/compagnies/al1-ant1/]
Pd-list@lists.iem.at[Pd-list@lists.iem.at] mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/listinfo/pd-list%5Bhttps://lists.puredata.info/l...]
-- Patrice Colet fr: 0632660357
Pd-list@lists.iem.at[Pd-list@lists.iem.at] mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/listinfo/pd-list%5Bhttps://lists.puredata.info/l...]
Pd-list@lists.iem.at[Pd-list@lists.iem.at] mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/listinfo/pd-list%5Bhttps://lists.puredata.info/l...]
--
Antoine Rousseau http://www.metalu.net%5Bhttp://metalu.net%5D%C2%A0__%C2%A0http://www.metalua...]
--
Antoine Rousseau http://www.metalu.net%5Bhttp://metalu.net%5D%C2%A0__%C2%A0http://www.metalua...] _______________________________________________ Pd-list@lists.iem.at mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/listinfo/pd-list%5Bhttps://lists.puredata.info/l...]