Hi,
Does anyone know if there is a way to access the canvas_list pointer from an external without including g_canvas.h? I want to be able to create a canvas and add it to the list of root canvases, but ideally I only want to use the public API (m_pd.h).
Jamie
Lots of externals use g_canvas.h, so it would not be such a big deal. The whole public/private header thing in Pd is not very well defined.
.hc
On May 3, 2007, at 3:01 AM, Jamie Bullock wrote:
Hi,
Does anyone know if there is a way to access the canvas_list pointer from an external without including g_canvas.h? I want to be able to create a canvas and add it to the list of root canvases, but ideally I only want to use the public API (m_pd.h).
Jamie
PD-dev mailing list PD-dev@iem.at http://lists.puredata.info/listinfo/pd-dev
------------------------------------------------------------------------ ----
Man has survived hitherto because he was too ignorant to know how to realize his wishes. Now that he can realize them, he must either change them, or perish. -William Carlos Williams
On Thu, 2007-05-03 at 18:12 -0400, Hans-Christoph Steiner wrote:
Lots of externals use g_canvas.h, so it would not be such a big deal. The whole public/private header thing in Pd is not very well defined.
I don't really have a problem with using g_canvas.h per se, it's more of a question of build requirements. m_pd.h usually tends to get installed to /usr/local/include or /usr/include when installing from source or some distro packaged version. However, if I use g_*.h headers, I have to either include them with my sources, or ask the user to add the necessary include path to the build scripts. Neither of these are very clean IMO.
Jamie
On May 4, 2007, at 7:37 AM, Jamie Bullock wrote:
On Thu, 2007-05-03 at 18:12 -0400, Hans-Christoph Steiner wrote:
Lots of externals use g_canvas.h, so it would not be such a big deal. The whole public/private header thing in Pd is not very well defined.
I don't really have a problem with using g_canvas.h per se, it's more of a question of build requirements. m_pd.h usually tends to get installed to /usr/local/include or /usr/include when installing from source or some distro packaged version. However, if I use g_*.h headers, I have to either include them with my sources, or ask the user to add the necessary include path to the build scripts. Neither of these are very clean IMO.
Jamie
Yeah, it's not so clean. Most Makefiles deal with this by having a PDPATH variable that points to the whole source.
.hc
------------------------------------------------------------------------ ----
As we enjoy great advantages from inventions of others, we should be glad of an opportunity to serve others by any invention of ours; and this we should do freely and generously. - Benjamin Franklin