@@ -1438,6 +1438,62 @@ PHP_FUNCTION(vips_error_buffer)
1438
1438
}
1439
1439
/* }}} */
1440
1440
1441
+ /* {{{ proto void vips_cache_set_max(integer value)
1442
+ Set max number of operations to cache */
1443
+ PHP_FUNCTION (vips_cache_set_max )
1444
+ {
1445
+ long value ;
1446
+
1447
+ if (zend_parse_parameters (ZEND_NUM_ARGS (), "l" , & value ) == FAILURE ) {
1448
+ return ;
1449
+ }
1450
+
1451
+ vips_cache_set_max (value );
1452
+ }
1453
+ /* }}} */
1454
+
1455
+ /* {{{ proto void vips_cache_set_max_mem(integer value)
1456
+ Set max memory to use for operation cache */
1457
+ PHP_FUNCTION (vips_cache_set_max_mem )
1458
+ {
1459
+ long value ;
1460
+
1461
+ if (zend_parse_parameters (ZEND_NUM_ARGS (), "l" , & value ) == FAILURE ) {
1462
+ return ;
1463
+ }
1464
+
1465
+ vips_cache_set_max_mem (value );
1466
+ }
1467
+ /* }}} */
1468
+
1469
+ /* {{{ proto void vips_cache_set_max_files(integer value)
1470
+ Set max number of open files for operation cache */
1471
+ PHP_FUNCTION (vips_cache_set_max_files )
1472
+ {
1473
+ long value ;
1474
+
1475
+ if (zend_parse_parameters (ZEND_NUM_ARGS (), "l" , & value ) == FAILURE ) {
1476
+ return ;
1477
+ }
1478
+
1479
+ vips_cache_set_max_files (value );
1480
+ }
1481
+ /* }}} */
1482
+
1483
+ /* {{{ proto void vips_concurrency_set(integer value)
1484
+ Set number of workers per threadpool */
1485
+ PHP_FUNCTION (vips_concurrency_set )
1486
+ {
1487
+ long value ;
1488
+
1489
+ if (zend_parse_parameters (ZEND_NUM_ARGS (), "l" , & value ) == FAILURE ) {
1490
+ return ;
1491
+ }
1492
+
1493
+ vips_concurrency_set (value );
1494
+ }
1495
+ /* }}} */
1496
+
1441
1497
/* {{{ php_vips_init_globals
1442
1498
*/
1443
1499
/* Uncomment this function if you have INI entries
@@ -1588,6 +1644,22 @@ ZEND_END_ARG_INFO()
1588
1644
ZEND_BEGIN_ARG_INFO (arginfo_vips_error_buffer , 0 )
1589
1645
ZEND_END_ARG_INFO ()
1590
1646
1647
+ ZEND_BEGIN_ARG_INFO (arginfo_vips_cache_set_max , 0 )
1648
+ ZEND_ARG_INFO (0 , value )
1649
+ ZEND_END_ARG_INFO ()
1650
+
1651
+ ZEND_BEGIN_ARG_INFO (arginfo_vips_cache_set_max_mem , 0 )
1652
+ ZEND_ARG_INFO (0 , value )
1653
+ ZEND_END_ARG_INFO ()
1654
+
1655
+ ZEND_BEGIN_ARG_INFO (arginfo_vips_cache_set_max_files , 0 )
1656
+ ZEND_ARG_INFO (0 , value )
1657
+ ZEND_END_ARG_INFO ()
1658
+
1659
+ ZEND_BEGIN_ARG_INFO (arginfo_vips_concurrency_set , 0 )
1660
+ ZEND_ARG_INFO (0 , value )
1661
+ ZEND_END_ARG_INFO ()
1662
+
1591
1663
/* {{{ vips_functions[]
1592
1664
*
1593
1665
* Every user visible function must have an entry in vips_functions[].
@@ -1604,6 +1676,10 @@ const zend_function_entry vips_functions[] = {
1604
1676
PHP_FE (vips_image_set , arginfo_vips_image_set )
1605
1677
PHP_FE (vips_image_remove , arginfo_vips_image_remove )
1606
1678
PHP_FE (vips_error_buffer , arginfo_vips_error_buffer )
1679
+ PHP_FE (vips_cache_set_max , arginfo_vips_cache_set_max )
1680
+ PHP_FE (vips_cache_set_max_mem , arginfo_vips_cache_set_max_mem )
1681
+ PHP_FE (vips_cache_set_max_files , arginfo_vips_cache_set_max_files )
1682
+ PHP_FE (vips_concurrency_set , arginfo_vips_concurrency_set )
1607
1683
1608
1684
PHP_FE_END /* Must be the last line in vips_functions[] */
1609
1685
};
0 commit comments