github.com/kaydxh/golang@v0.0.131/pkg/gocv/cgo/third_path/graphics-magick/include/GraphicsMagick/magick/memory.h (about)

     1  /*
     2    Copyright (C) 2003-2020 GraphicsMagick Group
     3  
     4    This program is covered by multiple licenses, which are described in
     5    Copyright.txt. You should have received a copy of Copyright.txt with this
     6    package; otherwise see http://www.graphicsmagick.org/www/Copyright.html.
     7  
     8    GraphicsMagick Memory Allocation Methods.
     9  */
    10  #ifndef _MAGICK_MEMORY_H
    11  #define _MAGICK_MEMORY_H
    12  
    13  #if defined(__cplusplus) || defined(c_plusplus)
    14  extern "C" {
    15  #endif
    16  
    17  typedef void *(*MagickMallocFunc)(size_t size);
    18  typedef void (*MagickFreeFunc)(void *ptr);
    19  typedef void *(*MagickReallocFunc)(void *ptr, size_t size);
    20  
    21  extern MagickExport void
    22     MagickAllocFunctions(MagickFreeFunc free_func,MagickMallocFunc malloc_func,
    23                          MagickReallocFunc realloc_func),
    24    *MagickMalloc(const size_t size) MAGICK_FUNC_MALLOC MAGICK_FUNC_ALLOC_SIZE_1ARG(1),
    25    *MagickMallocAligned(const size_t alignment, const size_t size) MAGICK_FUNC_MALLOC MAGICK_FUNC_ALLOC_SIZE_1ARG(2),
    26    *MagickMallocCleared(const size_t size) MAGICK_FUNC_MALLOC MAGICK_FUNC_ALLOC_SIZE_1ARG(1),
    27    *MagickCloneMemory(void *destination,const void *source,const size_t size) MAGICK_FUNC_NONNULL,
    28    *MagickRealloc(void *memory,const size_t size) MAGICK_FUNC_MALLOC MAGICK_FUNC_ALLOC_SIZE_1ARG(2),
    29     MagickFree(void *memory),
    30     MagickFreeAligned(void *memory);
    31  
    32  #if defined(MAGICK_IMPLEMENTATION)
    33  #include "magick/memory-private.h"
    34  #endif /* defined(MAGICK_IMPLEMENTATION) */
    35  
    36  #if defined(__cplusplus) || defined(c_plusplus)
    37  }
    38  #endif
    39  
    40  #endif
    41  
    42  /*
    43   * Local Variables:
    44   * mode: c
    45   * c-basic-offset: 2
    46   * fill-column: 78
    47   * End:
    48   */