Typedefs | |
| typedef stp_array | stp_array_t |
| The array opaque data type. | |
Functions | |
| stp_array_t * | stp_array_create (int x_size, int y_size) |
| Create a new array. | |
| void | stp_array_destroy (stp_array_t *array) |
| Destroy an array. | |
| void | stp_array_copy (stp_array_t *dest, const stp_array_t *source) |
| Copy an array. | |
| stp_array_t * | stp_array_create_copy (const stp_array_t *array) |
| Copy and allocate an array. | |
| void | stp_array_set_size (stp_array_t *array, int x_size, int y_size) |
| Resize an array. | |
| void | stp_array_get_size (const stp_array_t *array, int *x_size, int *y_size) |
| Get the size of an array. | |
| void | stp_array_set_data (stp_array_t *array, const double *data) |
| Set the data in an array. | |
| void | stp_array_get_data (const stp_array_t *array, size_t *size, const double **data) |
| Get the data in an array. | |
| int | stp_array_set_point (stp_array_t *array, int x, int y, double data) |
| Set the data at a single point in the array. | |
| int | stp_array_get_point (const stp_array_t *array, int x, int y, double *data) |
| Get the data at a single point in the array. | |
| const stp_sequence_t * | stp_array_get_sequence (const stp_array_t *array) |
| Get the underlying stp_sequence_t. | |
array "inherits" from the sequence data structure (implemented via containment).
|
|
||||||||||||
|
Copy an array. Both dest and source must be valid arrays previously created with stp_array_create().
Definition at line 94 of file array.c. References check_array(), stp_array::data, stp_array_t, stp_sequence_create_copy(), stp_sequence_destroy(), stp_array::x_size, and stp_array::y_size. Referenced by stp_array_create_copy(). |
|
||||||||||||
|
Create a new array. The total size of the array will be (x_size * y_size).
Definition at line 65 of file array.c. References array_ctor(), stp_array::data, stp_array_t, stp_zalloc(), stp_array::x_size, and stp_array::y_size. Referenced by stp_array_create_copy(), and stp_array_create_from_xmltree(). |
|
|
Copy and allocate an array. dest will be created, and then the contents of source will be copied into it. dest must not have been previously allocated with stp_array_create().
Definition at line 107 of file array.c. References check_array(), stp_array_copy(), stp_array_create(), and stp_array_t. Referenced by stp_set_array_parameter(), stp_set_default_array_parameter(), stp_xml_get_dither_array(), and value_copy(). |
|
|
Destroy an array. It is an error to destroy the array more than once.
Definition at line 86 of file array.c. References array_dtor(), check_array(), stp_array_t, and stp_free(). Referenced by stp_array_create_from_xmltree(), stp_dither_init(), stp_parameter_description_destroy(), stp_printer_create_from_xmltree(), stp_set_array_parameter(), and value_freefunc(). |
|
||||||||||||||||
|
Get the data in an array.
Definition at line 147 of file array.c. References check_array(), stp_array::data, stp_array_t, and stp_sequence_get_data(). |
|
||||||||||||||||||||
|
Get the data at a single point in the array.
Definition at line 164 of file array.c. References check_array(), stp_array::data, stp_array_t, stp_sequence_get_point(), stp_array::x_size, and stp_array::y_size. |
|
|
Get the underlying stp_sequence_t.
Definition at line 175 of file array.c. References check_array(), stp_array::data, and stp_array_t. Referenced by stp_dither_matrix_init_from_dither_array(), stp_dither_matrix_validate_array(), and stp_xmltree_create_from_array(). |
|
||||||||||||||||
|
Get the size of an array. The current x and y sizes are stored in the integers pointed to by x_size and y_size.
Definition at line 130 of file array.c. References check_array(), stp_array_t, stp_array::x_size, and stp_array::y_size. Referenced by stp_dither_matrix_init_from_dither_array(), and stp_xmltree_create_from_array(). |
|
||||||||||||
|
Set the data in an array.
Definition at line 139 of file array.c. References check_array(), stp_array::data, stp_array_t, stp_sequence_set_data(), stp_array::x_size, and stp_array::y_size. |
|
||||||||||||||||||||
|
Set the data at a single point in the array.
Definition at line 154 of file array.c. References check_array(), stp_array::data, stp_array_t, stp_sequence_set_point(), stp_array::x_size, and stp_array::y_size. |
|
||||||||||||||||
|
Resize an array. Resizing an array will destroy all data stored in the array.
Definition at line 118 of file array.c. References check_array(), stp_array::data, stp_array_t, stp_sequence_create(), stp_sequence_destroy(), stp_sequence_set_size(), stp_array::x_size, and stp_array::y_size. |
1.3.6