#include <gimp-print/gimp-print.h>
#include "gimp-print-internal.h"
#include <math.h>
#include <string.h>
#include <stdlib.h>
#include <stdio.h>
#include <assert.h>
#include "dither-impl.h"
Go to the source code of this file.
Data Structures | |
struct | stp_xml_dither_cache_t |
Defines | |
#define | MATRIX_POINT(m, x, y, x_size, y_size) ((m)[(((x) + (x_size)) % (x_size)) + ((x_size) * (((y) + (y_size)) % (y_size)))]) |
Functions | |
unsigned | gcd (unsigned a, unsigned b) |
int | calc_ordered_point (unsigned x, unsigned y, int steps, int multiplier, int size, const unsigned *map) |
int | is_po2 (size_t i) |
void | stp_dither_matrix_iterated_init (stp_dither_matrix_impl_t *mat, size_t size, size_t expt, const unsigned *array) |
void | stp_dither_matrix_shear (stp_dither_matrix_impl_t *mat, int x_shear, int y_shear) |
int | stp_dither_matrix_validate_array (const stp_array_t *array) |
void | stp_dither_matrix_init_from_dither_array (stp_dither_matrix_impl_t *mat, const stp_array_t *array, int transpose) |
void | stp_dither_matrix_init (stp_dither_matrix_impl_t *mat, int x_size, int y_size, const unsigned int *array, int transpose, int prescaled) |
void | stp_dither_matrix_init_short (stp_dither_matrix_impl_t *mat, int x_size, int y_size, const unsigned short *array, int transpose, int prescaled) |
void | stp_dither_matrix_destroy (stp_dither_matrix_impl_t *mat) |
void | stp_dither_matrix_clone (const stp_dither_matrix_impl_t *src, stp_dither_matrix_impl_t *dest, int x_offset, int y_offset) |
void | stp_dither_matrix_copy (const stp_dither_matrix_impl_t *src, stp_dither_matrix_impl_t *dest) |
void | stp_dither_matrix_scale_exponentially (stp_dither_matrix_impl_t *mat, double exponent) |
void | stp_dither_matrix_set_row (stp_dither_matrix_impl_t *mat, int y) |
void | preinit_matrix (stp_vars_t *v) |
void | postinit_matrix (stp_vars_t *v, int x_shear, int y_shear) |
void | stp_dither_set_iterated_matrix (stp_vars_t *v, size_t edge, size_t iterations, const unsigned *data, int prescaled, int x_shear, int y_shear) |
void | stp_dither_set_matrix (stp_vars_t *v, const stp_dither_matrix_generic_t *matrix, int transposed, int x_shear, int y_shear) |
void | stp_dither_set_matrix_from_dither_array (stp_vars_t *v, const stp_array_t *array, int transpose) |
void | stp_dither_set_transition (stp_vars_t *v, double exponent) |
stp_xml_dither_cache_t * | stp_xml_dither_cache_get (int x, int y) |
void | stp_xml_dither_cache_set (int x, int y, const char *filename) |
int | stp_xml_process_dither_matrix (stp_mxml_node_t *dm, const char *file) |
stp_array_t * | stpi_dither_array_create_from_xmltree (stp_mxml_node_t *dm) |
stp_array_t * | xml_doc_get_dither_array (stp_mxml_node_t *doc) |
stp_array_t * | stpi_dither_array_create_from_file (const char *file) |
stp_array_t * | stp_xml_get_dither_array (int x, int y) |
void | stpi_init_dither (void) |
stp_array_t * | stp_find_standard_dither_array (int x_aspect, int y_aspect) |
Variables | |
stp_list_t * | dither_matrix_cache = NULL |
|
Definition at line 128 of file print-dither-matrices.c. Referenced by stp_dither_matrix_shear(). |
|
Definition at line 65 of file print-dither-matrices.c. Referenced by stp_dither_matrix_iterated_init(). |
|
Definition at line 45 of file print-dither-matrices.c. |
|
Definition at line 88 of file print-dither-matrices.c. Referenced by stp_dither_matrix_init(), stp_dither_matrix_init_from_dither_array(), stp_dither_matrix_init_short(), and stp_dither_matrix_iterated_init(). |
|
Definition at line 356 of file print-dither-matrices.c. References CHANNEL, CHANNEL_COUNT, dither::dither_matrix, stp_dither_matrix_clone(), stp_dither_matrix_shear(), stp_dither_set_transition(), stp_get_component_data(), stp_vars_t, stpi_dither_t, dither::transition, dither_matrix_impl::x_size, and dither_matrix_impl::y_size. Referenced by stp_dither_set_iterated_matrix(), stp_dither_set_matrix(), and stp_dither_set_matrix_from_dither_array(). |
|
Definition at line 346 of file print-dither-matrices.c. References CHANNEL, CHANNEL_COUNT, dither::dither_matrix, stp_dither_matrix_destroy(), stp_get_component_data(), stp_vars_t, and stpi_dither_t. Referenced by stp_dither_set_iterated_matrix(), stp_dither_set_matrix(), and stp_dither_set_matrix_from_dither_array(). |
|
|
|
Definition at line 267 of file print-dither-matrices.c. References dither_matrix_impl::base, dither_matrix_impl::exp, dither_matrix_impl::i_own, dither_matrix_impl::matrix, stp_dither_matrix_impl_t, stp_free(), dither_matrix_impl::total_size, dither_matrix_impl::x_size, and dither_matrix_impl::y_size. Referenced by preinit_matrix(), stp_dither_set_transition(), stpi_dither_channel_destroy(), and stpi_dither_free(). |
|
|
|
|
|
Definition at line 325 of file print-dither-matrices.c. References dither_matrix_impl::matrix, stp_dither_matrix_impl_t, dither_matrix_impl::x_size, and dither_matrix_impl::y_size. Referenced by stp_dither_set_transition(). |
|
Definition at line 338 of file print-dither-matrices.c. References dither_matrix_impl::index, dither_matrix_impl::last_x_mod, dither_matrix_impl::last_y, dither_matrix_impl::last_y_mod, stp_dither_matrix_impl_t, dither_matrix_impl::x_size, dither_matrix_impl::y_offset, and dither_matrix_impl::y_size. Referenced by stp_dither_internal(). |
|
Definition at line 132 of file print-dither-matrices.c. References dither_matrix_impl::matrix, MATRIX_POINT, stp_dither_matrix_impl_t, stp_free(), stp_malloc(), dither_matrix_impl::x_size, and dither_matrix_impl::y_size. Referenced by postinit_matrix(). |
|
Definition at line 150 of file print-dither-matrices.c. References stp_array_get_sequence(), stp_array_t, stp_sequence_get_bounds(), and stp_sequence_t. Referenced by stp_dither_init(). |
|
Definition at line 379 of file print-dither-matrices.c. References dither::dither_matrix, postinit_matrix(), preinit_matrix(), stp_dither_matrix_iterated_init(), stp_get_component_data(), stp_vars_t, and stpi_dither_t. Referenced by stp_dither_init(). |
|
|
Definition at line 409 of file print-dither-matrices.c. References dither::dither_matrix, postinit_matrix(), preinit_matrix(), stp_array_t, stp_dither_matrix_init_from_dither_array(), stp_get_component_data(), stp_vars_t, and stpi_dither_t. Referenced by stp_dither_init(). |
|
Definition at line 420 of file print-dither-matrices.c. References CHANNEL, CHANNEL_COUNT, dither::dither_matrix, stp_dither_matrix_clone(), stp_dither_matrix_copy(), stp_dither_matrix_destroy(), stp_dither_matrix_scale_exponentially(), stp_get_component_data(), stp_vars_t, stpi_dither_t, dither::transition, dither::transition_matrix, dither_matrix_impl::x_size, and dither_matrix_impl::y_size. Referenced by postinit_matrix(), and stp_dither_init(). |
|
Definition at line 683 of file print-dither-matrices.c. References gcd(), stp_array_t, and stp_xml_get_dither_array(). Referenced by stp_dither_init(). |
|
Definition at line 457 of file print-dither-matrices.c. References dither_matrix_cache, STP_DBG_XML, stp_deprintf(), stp_list_get_start(), stp_list_item_get_data(), stp_list_item_next(), and stp_list_item_t. Referenced by stp_xml_dither_cache_set(), and stp_xml_get_dither_array(). |
|
Definition at line 489 of file print-dither-matrices.c. References assert, stp_xml_dither_cache_t::dither_array, dither_matrix_cache, stp_xml_dither_cache_t::filename, STP_DBG_XML, stp_deprintf(), stp_list_create(), stp_list_item_create(), stp_malloc(), stp_strdup(), stp_xml_dither_cache_get(), stp_xml_exit(), stp_xml_init(), stp_xml_dither_cache_t::x, and stp_xml_dither_cache_t::y. Referenced by stp_xml_process_dither_matrix(). |
|
Definition at line 648 of file print-dither-matrices.c. References stp_xml_dither_cache_t::dither_array, stp_xml_dither_cache_t::filename, stp_array_create_copy(), stp_array_t, stp_xml_dither_cache_get(), stp_xml_parse_file_named(), and stpi_dither_array_create_from_file(). Referenced by stp_find_standard_dither_array(). |
|
Definition at line 523 of file print-dither-matrices.c. References STP_DBG_XML, stp_deprintf(), stp_mxml_node_t, stp_mxmlElementGetAttr(), stp_xml_dither_cache_set(), and stp_xmlstrtol(). Referenced by stpi_init_dither(). |
|
Definition at line 615 of file print-dither-matrices.c. References stp_array_t, STP_DBG_XML, stp_deprintf(), stp_erprintf(), STP_MXML_NO_CALLBACK, stp_mxml_node_t, stp_mxmlDelete(), stp_mxmlLoadFile(), stp_xml_exit(), stp_xml_init(), and xml_doc_get_dither_array(). Referenced by stp_xml_get_dither_array(). |
|
Definition at line 545 of file print-dither-matrices.c. References stp_array_create_from_xmltree(), stp_erprintf(), STP_MXML_DESCEND, stp_mxml_node_t, stp_mxmlElementGetAttr(), stp_mxmlFindElement(), and stp_xmlstrtoul(). Referenced by xml_doc_get_dither_array(). |
|
Definition at line 585 of file print-dither-matrices.c. References stp_mxml_node_s::child, stp_mxml_node_t, stp_xml_get_node(), and stpi_dither_array_create_from_xmltree(). Referenced by stpi_dither_array_create_from_file(). |
|
Definition at line 446 of file print-dither-matrices.c. Referenced by stp_xml_dither_cache_get(), and stp_xml_dither_cache_set(). |