From 111400ff6859f275683ddedc8d786967cd2c7fb3 Mon Sep 17 00:00:00 2001 From: Mattias Andrée Date: Wed, 17 Jul 2024 22:40:34 +0200 Subject: Update for libgamma 0.7.4 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Mattias Andrée --- libgamma_native_method.pyx | 72 +++++++++++++++++++++++----------------------- 1 file changed, 36 insertions(+), 36 deletions(-) (limited to 'libgamma_native_method.pyx') diff --git a/libgamma_native_method.pyx b/libgamma_native_method.pyx index 96eee7c..9ea9ded 100644 --- a/libgamma_native_method.pyx +++ b/libgamma_native_method.pyx @@ -9,7 +9,7 @@ from libc.errno cimport errno cdef extern from "include-libgamma.h": - ctypedef struct libgamma_gamma_ramps8_t: + ctypedef struct libgamma_gamma_ramps8 "struct libgamma_gamma_ramps8": # Gamma ramp structure for 8-bit gamma ramps size_t red_size # The size of `red` size_t green_size # The size of `green` @@ -18,7 +18,7 @@ cdef extern from "include-libgamma.h": uint8_t *green # The gamma ramp for the green channel uint8_t *blue # The gamma ramp for the blue channel - ctypedef struct libgamma_gamma_ramps16_t: + ctypedef struct libgamma_gamma_ramps16 "struct libgamma_gamma_ramps16": # Gamma ramp structure for 16-bit gamma ramps size_t red_size # The size of `red` size_t green_size # The size of `green` @@ -27,7 +27,7 @@ cdef extern from "include-libgamma.h": uint16_t *green # The gamma ramp for the green channel uint16_t *blue # The gamma ramp for the blue channel - ctypedef struct libgamma_gamma_ramps32_t: + ctypedef struct libgamma_gamma_ramps32 "struct libgamma_gamma_ramps32": # Gamma ramp structure for 32-bit gamma ramps size_t red_size # The size of `red` size_t green_size # The size of `green` @@ -36,7 +36,7 @@ cdef extern from "include-libgamma.h": uint32_t *green # The gamma ramp for the green channel uint32_t *blue # The gamma ramp for the blue channel - ctypedef struct libgamma_gamma_ramps64_t: + ctypedef struct libgamma_gamma_ramps64 "struct libgamma_gamma_ramps64": # Gamma ramp structure for 64-bit gamma ramps size_t red_size # The size of `red` size_t green_size # The size of `green` @@ -45,7 +45,7 @@ cdef extern from "include-libgamma.h": uint64_t *green # The gamma ramp for the green channel uint64_t *blue # The gamma ramp for the blue channel - ctypedef struct libgamma_gamma_rampsf_t: + ctypedef struct libgamma_gamma_rampsf "struct libgamma_gamma_rampsf": # Gamma ramp structure for `float` gamma ramps size_t red_size # The size of `red` size_t green_size # The size of `green` @@ -54,7 +54,7 @@ cdef extern from "include-libgamma.h": float *green # The gamma ramp for the green channel float *blue # The gamma ramp for the blue channel - ctypedef struct libgamma_gamma_rampsd_t: + ctypedef struct libgamma_gamma_rampsd "struct libgamma_gamma_rampsd": # Gamma ramp structure for `double` gamma ramps size_t red_size # The size of `red` size_t green_size # The size of `green` @@ -63,7 +63,7 @@ cdef extern from "include-libgamma.h": double *green # The gamma ramp for the green channel double *blue # The gamma ramp for the blue channel -cdef extern int libgamma_gamma_ramps8_initialise(libgamma_gamma_ramps8_t *this) nogil +cdef extern int libgamma_gamma_ramps8_initialise(libgamma_gamma_ramps8 *this) nogil ''' Initialise a gamma ramp in the proper way that allows all adjustment methods to read from and write to it without causing segmentation violation @@ -75,7 +75,7 @@ set to the sizes of the gamma ramps that should be allocated @return Zero on success, -1 on allocation error, `errno` will be set accordingly ''' -cdef extern void libgamma_gamma_ramps8_free(libgamma_gamma_ramps8_t *this) nogil +cdef extern void libgamma_gamma_ramps8_free(libgamma_gamma_ramps8 *this) nogil ''' Release resources that are held by a gamma ramp strcuture that has been allocated by `libgamma_gamma_ramps8_initialise` or @@ -85,7 +85,7 @@ the pointer to the structure @param this The gamma ramps ''' -cdef extern int libgamma_gamma_ramps16_initialise(libgamma_gamma_ramps16_t *this) nogil +cdef extern int libgamma_gamma_ramps16_initialise(libgamma_gamma_ramps16 *this) nogil ''' Initialise a gamma ramp in the proper way that allows all adjustment methods to read from and write to it without causing segmentation violation @@ -97,7 +97,7 @@ set to the sizes of the gamma ramps that should be allocated @return Zero on success, -1 on allocation error, `errno` will be set accordingly ''' -cdef extern void libgamma_gamma_ramps16_free(libgamma_gamma_ramps16_t *this) nogil +cdef extern void libgamma_gamma_ramps16_free(libgamma_gamma_ramps16 *this) nogil ''' Release resources that are held by a gamma ramp strcuture that has been allocated by `libgamma_gamma_ramps16_initialise` or @@ -107,7 +107,7 @@ the pointer to the structure @param this The gamma ramps ''' -cdef extern int libgamma_gamma_ramps32_initialise(libgamma_gamma_ramps32_t *this) nogil +cdef extern int libgamma_gamma_ramps32_initialise(libgamma_gamma_ramps32 *this) nogil ''' Initialise a gamma ramp in the proper way that allows all adjustment methods to read from and write to it without causing segmentation violation @@ -119,7 +119,7 @@ set to the sizes of the gamma ramps that should be allocated @return Zero on success, -1 on allocation error, `errno` will be set accordingly ''' -cdef extern void libgamma_gamma_ramps32_free(libgamma_gamma_ramps32_t *this) nogil +cdef extern void libgamma_gamma_ramps32_free(libgamma_gamma_ramps32 *this) nogil ''' Release resources that are held by a gamma ramp strcuture that has been allocated by `libgamma_gamma_ramps32_initialise` or @@ -129,7 +129,7 @@ the pointer to the structure @param this The gamma ramps ''' -cdef extern int libgamma_gamma_ramps64_initialise(libgamma_gamma_ramps64_t *this) nogil +cdef extern int libgamma_gamma_ramps64_initialise(libgamma_gamma_ramps64 *this) nogil ''' Initialise a gamma ramp in the proper way that allows all adjustment methods to read from and write to it without causing segmentation violation @@ -141,7 +141,7 @@ set to the sizes of the gamma ramps that should be allocated @return Zero on success, -1 on allocation error, `errno` will be set accordingly ''' -cdef extern void libgamma_gamma_ramps64_free(libgamma_gamma_ramps64_t *this) nogil +cdef extern void libgamma_gamma_ramps64_free(libgamma_gamma_ramps64 *this) nogil ''' Release resources that are held by a gamma ramp strcuture that has been allocated by `libgamma_gamma_ramps64_initialise` or @@ -151,7 +151,7 @@ the pointer to the structure @param this The gamma ramps ''' -cdef extern int libgamma_gamma_rampsf_initialise(libgamma_gamma_rampsf_t *this) nogil +cdef extern int libgamma_gamma_rampsf_initialise(libgamma_gamma_rampsf *this) nogil ''' Initialise a gamma ramp in the proper way that allows all adjustment methods to read from and write to it without causing segmentation violation @@ -163,7 +163,7 @@ set to the sizes of the gamma ramps that should be allocated @return Zero on success, -1 on allocation error, `errno` will be set accordingly ''' -cdef extern void libgamma_gamma_rampsf_free(libgamma_gamma_rampsf_t *this) nogil +cdef extern void libgamma_gamma_rampsf_free(libgamma_gamma_rampsf *this) nogil ''' Release resources that are held by a gamma ramp strcuture that has been allocated by `libgamma_gamma_rampsf_initialise` or @@ -173,7 +173,7 @@ the pointer to the structure @param this The gamma ramps ''' -cdef extern int libgamma_gamma_rampsd_initialise(libgamma_gamma_rampsd_t *this) nogil +cdef extern int libgamma_gamma_rampsd_initialise(libgamma_gamma_rampsd *this) nogil ''' Initialise a gamma ramp in the proper way that allows all adjustment methods to read from and write to it without causing segmentation violation @@ -185,7 +185,7 @@ set to the sizes of the gamma ramps that should be allocated @return Zero on success, -1 on allocation error, `errno` will be set accordingly ''' -cdef extern void libgamma_gamma_rampsd_free(libgamma_gamma_rampsd_t *this) nogil +cdef extern void libgamma_gamma_rampsd_free(libgamma_gamma_rampsd *this) nogil ''' Release resources that are held by a gamma ramp strcuture that has been allocated by `libgamma_gamma_rampsd_initialise` or @@ -210,8 +210,8 @@ def libgamma_native_gamma_ramps8_create(red_size : int, green_size : int, blue_s Element 3: The address of the gamma ramp for the green channel Element 4: The address of the gamma ramp for the blue channel ''' - cdef void *allocation = malloc(sizeof(libgamma_gamma_ramps8_t)) - cdef libgamma_gamma_ramps8_t *item = allocation + cdef void *allocation = malloc(sizeof(libgamma_gamma_ramps8)) + cdef libgamma_gamma_ramps8 *item = allocation cdef size_t red, green, blue if item is NULL: return int(errno) @@ -236,7 +236,7 @@ def libgamma_native_gamma_ramps8_free(this : int): @param this The gamma ramps ''' cdef void *address = this - cdef libgamma_gamma_ramps8_t *item = address + cdef libgamma_gamma_ramps8 *item = address libgamma_gamma_ramps8_free(item) @@ -280,8 +280,8 @@ def libgamma_native_gamma_ramps16_create(red_size : int, green_size : int, blue_ Element 3: The address of the gamma ramp for the green channel Element 4: The address of the gamma ramp for the blue channel ''' - cdef void *allocation = malloc(sizeof(libgamma_gamma_ramps16_t)) - cdef libgamma_gamma_ramps16_t *item = allocation + cdef void *allocation = malloc(sizeof(libgamma_gamma_ramps16)) + cdef libgamma_gamma_ramps16 *item = allocation cdef size_t red, green, blue if item is NULL: return int(errno) @@ -306,7 +306,7 @@ def libgamma_native_gamma_ramps16_free(this : int): @param this The gamma ramps ''' cdef void *address = this - cdef libgamma_gamma_ramps16_t *item = address + cdef libgamma_gamma_ramps16 *item = address libgamma_gamma_ramps16_free(item) @@ -350,8 +350,8 @@ def libgamma_native_gamma_ramps32_create(red_size : int, green_size : int, blue_ Element 3: The address of the gamma ramp for the green channel Element 4: The address of the gamma ramp for the blue channel ''' - cdef void *allocation = malloc(sizeof(libgamma_gamma_ramps32_t)) - cdef libgamma_gamma_ramps32_t *item = allocation + cdef void *allocation = malloc(sizeof(libgamma_gamma_ramps32)) + cdef libgamma_gamma_ramps32 *item = allocation cdef size_t red, green, blue if item is NULL: return int(errno) @@ -376,7 +376,7 @@ def libgamma_native_gamma_ramps32_free(this : int): @param this The gamma ramps ''' cdef void *address = this - cdef libgamma_gamma_ramps32_t *item = address + cdef libgamma_gamma_ramps32 *item = address libgamma_gamma_ramps32_free(item) @@ -420,8 +420,8 @@ def libgamma_native_gamma_ramps64_create(red_size : int, green_size : int, blue_ Element 3: The address of the gamma ramp for the green channel Element 4: The address of the gamma ramp for the blue channel ''' - cdef void *allocation = malloc(sizeof(libgamma_gamma_ramps64_t)) - cdef libgamma_gamma_ramps64_t *item = allocation + cdef void *allocation = malloc(sizeof(libgamma_gamma_ramps64)) + cdef libgamma_gamma_ramps64 *item = allocation cdef size_t red, green, blue if item is NULL: return int(errno) @@ -446,7 +446,7 @@ def libgamma_native_gamma_ramps64_free(this : int): @param this The gamma ramps ''' cdef void *address = this - cdef libgamma_gamma_ramps64_t *item = address + cdef libgamma_gamma_ramps64 *item = address libgamma_gamma_ramps64_free(item) @@ -490,8 +490,8 @@ def libgamma_native_gamma_rampsf_create(red_size : int, green_size : int, blue_s Element 3: The address of the gamma ramp for the green channel Element 4: The address of the gamma ramp for the blue channel ''' - cdef void *allocation = malloc(sizeof(libgamma_gamma_rampsf_t)) - cdef libgamma_gamma_rampsf_t *item = allocation + cdef void *allocation = malloc(sizeof(libgamma_gamma_rampsf)) + cdef libgamma_gamma_rampsf *item = allocation cdef size_t red, green, blue if item is NULL: return int(errno) @@ -516,7 +516,7 @@ def libgamma_native_gamma_rampsf_free(this : int): @param this The gamma ramps ''' cdef void *address = this - cdef libgamma_gamma_rampsf_t *item = address + cdef libgamma_gamma_rampsf *item = address libgamma_gamma_rampsf_free(item) @@ -560,8 +560,8 @@ def libgamma_native_gamma_rampsd_create(red_size : int, green_size : int, blue_s Element 3: The address of the gamma ramp for the green channel Element 4: The address of the gamma ramp for the blue channel ''' - cdef void *allocation = malloc(sizeof(libgamma_gamma_rampsd_t)) - cdef libgamma_gamma_rampsd_t *item = allocation + cdef void *allocation = malloc(sizeof(libgamma_gamma_rampsd)) + cdef libgamma_gamma_rampsd *item = allocation cdef size_t red, green, blue if item is NULL: return int(errno) @@ -586,7 +586,7 @@ def libgamma_native_gamma_rampsd_free(this : int): @param this The gamma ramps ''' cdef void *address = this - cdef libgamma_gamma_rampsd_t *item = address + cdef libgamma_gamma_rampsd *item = address libgamma_gamma_rampsd_free(item) -- cgit v1.2.3-70-g09d2