Changeset 3086 for libpipi/trunk
- Timestamp:
- Oct 24, 2008, 3:49:02 PM (12 years ago)
- Location:
- libpipi/trunk/pipi-php
- Files:
-
- 1 added
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
libpipi/trunk/pipi-php/examples/histogram.php
r3080 r3086 6 6 $histogram = pipi_new_histogram(); 7 7 $histogram_img = pipi_new(320, 200); 8 echopipi_get_image_histogram($img, $histogram, 1);9 echopipi_render_histogram($img_histogram, $histogram, 1);8 pipi_get_image_histogram($img, $histogram, 1); 9 pipi_render_histogram($img_histogram, $histogram, 1); 10 10 11 11 pipi_save($histogram_img, "out.png"); -
libpipi/trunk/pipi-php/php_pipi.c
r3080 r3086 203 203 204 204 PHP_FUNCTION(pipi_command) { 205 zval *res; 206 char *arg1, *arg2 = NULL; 207 int arg1_len, arg2_len; 208 if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs|s", &res, &arg1, &arg1_len, &arg2, &arg2_len) == FAILURE) { 209 RETURN_FALSE; 210 } 211 212 pipi_context_t *ctxt; 213 ZEND_FETCH_RESOURCE(ctxt, pipi_context_t*, &res, -1, PHP_PIPI_CONTEXT_RES_NAME, le_pipi_context); 214 215 if (arg2_len != 0) { 216 RETURN_LONG(pipi_command(ctxt, arg1, arg2)); 217 } 218 RETURN_LONG(pipi_command(ctxt, arg1)); 205 219 } 206 220
Note: See TracChangeset
for help on using the changeset viewer.