dynload.h 1.45 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
/*
    This file is part of darktable,
    copyright (c) 2011 Ulrich Pegelow

    darktable is free software: you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
    the Free Software Foundation, either version 3 of the License, or
    (at your option) any later version.

    darktable is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License
    along with darktable.  If not, see <http://www.gnu.org/licenses/>.
*/

19
#pragma once
20

21 22
#ifdef HAVE_OPENCL

23 24 25 26 27 28 29 30 31 32
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif

#include <glib.h>
#include <gmodule.h>

typedef struct dt_gmodule_t
{
  GModule *gmodule;
33
  char *library;
34
} dt_gmodule_t;
35 36 37 38 39 40 41 42 43 44 45


/* check if gmodules is supported on this platform */
int dt_gmodule_supported(void);

/* dynamically load library */
dt_gmodule_t *dt_gmodule_open(const char *);

/* get pointer to function */
int dt_gmodule_symbol(dt_gmodule_t *, const char *, void (**)(void));

46
#endif // HAVE_OPENCL
47

Richard Wonka's avatar
Richard Wonka committed
48
// modelines: These editor modelines have been set for all relevant files by tools/update_modelines.sh
49
// vim: shiftwidth=2 expandtab tabstop=2 cindent
Tobias Ellinghaus's avatar
Tobias Ellinghaus committed
50
// kate: tab-indents: off; indent-width 2; replace-tabs on; indent-mode cstyle; remove-trailing-spaces modified;