Accessing another extensions resource.. possible?

From: Date: Sat, 13 Aug 2005 16:06:59 +0000
Subject: Accessing another extensions resource.. possible?
Groups: php.pecl.dev 
Request: Send a blank email to pecl-dev+get-2751@lists.php.net to get a copy of this message
I have a question regarding resource management in PHP that I would absolutely appreciate any insight on- Can extension A get access to a resource created by extension B? For example- if I wanted to add in a new image function, could I get access to the GD extension's gdImage struct? I wrote an improved Breshenham line algorithm in php that renders the most beautiful antialiased lines I've ever seen. The problem is the php implementation for it is UBER slow. Hence I'm looking into writing my own extension to give it a speed boost. But I'm having a hard time finding the right approach to this. There's three ways I'm thinking this can be done- 1. Write my own extension based on GD from scratch 2. Inject my line drawing function into gd.h and gd.c (so it'd be a modified version of the gd extension that comes with php) 3. Write my own extension that is capable of accessing the gdImage struct from the GD extensions. I'd prefer not to write an entire image library from scratch. But I'll do it if 2 and 3 aren't possible/reasonable. Thanks everyone!

« previous php.pecl.dev (#2751) next »