cvs: php4 /ext/swf/ php_swf.h swf.c

From: Date: Tue, 23 May 2000 04:09:20 +0000
Subject: cvs: php4 /ext/swf/ php_swf.h swf.c
Groups: php.version4 
Request: Send a blank email to php-version4+get-15498@lists.php.net to get a copy of this message
sterling Tue May 23 06:09:20 2000 EDT Modified files: /php4/ext/swf swf.c php_swf.h Log: @-Add the swf_ortho function. (Sterling) Index: php4/ext/swf/swf.c diff -u php4/ext/swf/swf.c:1.13 php4/ext/swf/swf.c:1.14 --- php4/ext/swf/swf.c:1.13 Mon May 22 22:56:09 2000 +++ php4/ext/swf/swf.c Tue May 23 06:09:20 2000 @@ -16,7 +16,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: swf.c,v 1.13 2000/05/22 20:56:09 sterling Exp $ */ +/* $Id: swf.c,v 1.14 2000/05/23 04:09:20 sterling Exp $ */ #include "php.h" @@ -83,6 +83,7 @@ PHP_FE(swf_oncondition, NULL) PHP_FE(swf_endbutton, NULL) PHP_FE(swf_viewport, NULL) + PHP_FE(swf_ortho, NULL) PHP_FE(swf_ortho2, NULL) PHP_FE(swf_perspective, NULL) PHP_FE(swf_polarview, NULL) @@ -998,6 +999,28 @@ PHP_FUNCTION(swf_ortho2) { php_swf_geo_same(INTERNAL_FUNCTION_PARAM_PASSTHRU, 1); +} +/* }}} */ + +/* {{{ proto void swf_ortho(double xmin, double xmax, double ymin, double ymax, double zmin, double zmax) + Defines an orthographic mapping of user coordinates onto the current viewport */ +PHP_FUNCTION(swf_ortho) +{ + zval **xmin, **xmax, **ymin, **ymax, **zmin, **zmax; + if (ARG_COUNT(ht) != 6 || + zend_get_parameters_ex(6, &xmin, &xmax, &ymin, &ymax, &zmin, &zmax) == FAILURE) { + WRONG_PARAM_COUNT; + } + convert_to_double_ex(xmin); + convert_to_double_ex(xmax); + convert_to_double_ex(ymin); + convert_to_double_ex(ymax); + convert_to_double_ex(zmin); + convert_to_double_ex(zmax); + + swf_ortho((*xmin)->value.dval, (*xmax)->value.dval, + (*ymin)->value.dval, (*ymax)->value.dval, + (*zmin)->value.dval, (*zmax)->value.dval); } /* }}} */ Index: php4/ext/swf/php_swf.h diff -u php4/ext/swf/php_swf.h:1.5 php4/ext/swf/php_swf.h:1.6 --- php4/ext/swf/php_swf.h:1.5 Thu May 18 17:34:36 2000 +++ php4/ext/swf/php_swf.h Tue May 23 06:09:20 2000 @@ -16,7 +16,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: php_swf.h,v 1.5 2000/05/18 15:34:36 zeev Exp $ */ +/* $Id: php_swf.h,v 1.6 2000/05/23 04:09:20 sterling Exp $ */ #ifndef _PHP_SWF_H #define _PHP_SWF_H @@ -92,6 +92,7 @@ PHP_FUNCTION(swf_oncondition); PHP_FUNCTION(swf_endbutton); PHP_FUNCTION(swf_viewport); +PHP_FUNCTION(swf_ortho); PHP_FUNCTION(swf_ortho2); PHP_FUNCTION(swf_perspective); PHP_FUNCTION(swf_polarview);

« previous php.version4 (#15498) next »