diff options
| author | Jouni Ahto <jah@php.net> | 2000-02-28 16:52:03 +0000 |
|---|---|---|
| committer | Jouni Ahto <jah@php.net> | 2000-02-28 16:52:03 +0000 |
| commit | bafbbea0516641ac5df5e8d285ff79133f55b685 (patch) | |
| tree | 5f7a993bdd6c65fd184d6d21280b6663c7f5f561 /ext/gd/php_gd.h | |
| parent | fd629e6ee02b0b471f62918092e4dd94ae82b2f9 (diff) | |
| download | php-git-bafbbea0516641ac5df5e8d285ff79133f55b685.tar.gz | |
- Use *_ex-API and *_RESOURCE-macros (partial).
# Yell if this breaks all the hell loose. Otherwise I'll continue with the
# wonderful experience of learning PHP4/Zend-APIS.
Diffstat (limited to 'ext/gd/php_gd.h')
| -rw-r--r-- | ext/gd/php_gd.h | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/ext/gd/php_gd.h b/ext/gd/php_gd.h index 0426862063..3d5e37f742 100644 --- a/ext/gd/php_gd.h +++ b/ext/gd/php_gd.h @@ -56,6 +56,15 @@ extern zend_module_entry gd_module_entry; #define phpext_gd_ptr &gd_module_entry +typedef struct { + int le_gd; + int le_gd_font; +#if HAVE_LIBT1 + int le_ps_font; + int le_ps_enc; +#endif +} php_gd_globals; + /* gd.c functions */ PHP_MINFO_FUNCTION(gd); extern PHP_MINIT_FUNCTION(gd); @@ -108,6 +117,18 @@ PHP_FUNCTION(imagettfbbox); PHP_FUNCTION(imagettftext); #endif PHPAPI int phpi_get_le_gd(void); + + +#ifdef ZTS +#define GDLS_D php_gd_globals *gd_globals +#define GDG(v) (gd_globals->v) +#define GDLS_FETCH() php_gd_globals *gd_globals = ts_resource(gd_globals_id) +#else +#define GDLS_D +#define GDG(v) (gd_globals.v) +#define GDLS_FETCH() +#endif + #else #define phpext_gd_ptr NULL |
