vf_frei0r.c 16.4 KB
Newer Older
Stefano Sabatini's avatar
Stefano Sabatini committed
1
/*
2
 * Copyright (c) 2010 Stefano Sabatini
3
 * This file is part of Libav.
Stefano Sabatini's avatar
Stefano Sabatini committed
4
 *
5
 * Libav is free software; you can redistribute it and/or
Stefano Sabatini's avatar
Stefano Sabatini committed
6 7 8 9
 * modify it under the terms of the GNU Lesser General Public
 * License as published by the Free Software Foundation; either
 * version 2.1 of the License, or (at your option) any later version.
 *
10
 * Libav is distributed in the hope that it will be useful,
Stefano Sabatini's avatar
Stefano Sabatini committed
11 12 13 14 15
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public
16
 * License along with Libav; if not, write to the Free Software
Stefano Sabatini's avatar
Stefano Sabatini committed
17 18 19 20 21 22 23 24 25 26 27 28
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
 */

/**
 * @file
 * frei0r wrapper
 */

/* #define DEBUG */

#include <dlfcn.h>
#include <frei0r.h>
29 30 31 32
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include "config.h"
33
#include "libavutil/avstring.h"
34
#include "libavutil/imgutils.h"
35
#include "libavutil/internal.h"
36
#include "libavutil/mathematics.h"
37
#include "libavutil/mem.h"
38
#include "libavutil/parseutils.h"
Stefano Sabatini's avatar
Stefano Sabatini committed
39
#include "avfilter.h"
40
#include "formats.h"
41
#include "internal.h"
42
#include "video.h"
Stefano Sabatini's avatar
Stefano Sabatini committed
43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67

typedef f0r_instance_t (*f0r_construct_f)(unsigned int width, unsigned int height);
typedef void (*f0r_destruct_f)(f0r_instance_t instance);
typedef void (*f0r_deinit_f)(void);
typedef int (*f0r_init_f)(void);
typedef void (*f0r_get_plugin_info_f)(f0r_plugin_info_t *info);
typedef void (*f0r_get_param_info_f)(f0r_param_info_t *info, int param_index);
typedef void (*f0r_update_f)(f0r_instance_t instance, double time, const uint32_t *inframe, uint32_t *outframe);
typedef void (*f0r_update2_f)(f0r_instance_t instance, double time, const uint32_t *inframe1, const uint32_t *inframe2, const uint32_t *inframe3, uint32_t *outframe);
typedef void (*f0r_set_param_value_f)(f0r_instance_t instance, f0r_param_t param, int param_index);
typedef void (*f0r_get_param_value_f)(f0r_instance_t instance, f0r_param_t param, int param_index);

typedef struct Frei0rContext {
    f0r_update_f update;
    void *dl_handle;            /* dynamic library handle   */
    f0r_instance_t instance;
    f0r_plugin_info_t plugin_info;

    f0r_get_param_info_f  get_param_info;
    f0r_get_param_value_f get_param_value;
    f0r_set_param_value_f set_param_value;
    f0r_construct_f       construct;
    f0r_destruct_f        destruct;
    f0r_deinit_f          deinit;
    char params[256];
Stefano Sabatini's avatar
Stefano Sabatini committed
68 69 70 71 72

    /* only used by the source */
    int w, h;
    AVRational time_base;
    uint64_t pts;
Stefano Sabatini's avatar
Stefano Sabatini committed
73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109
} Frei0rContext;

static void *load_sym(AVFilterContext *ctx, const char *sym_name)
{
    Frei0rContext *frei0r = ctx->priv;
    void *sym = dlsym(frei0r->dl_handle, sym_name);
    if (!sym)
        av_log(ctx, AV_LOG_ERROR, "Could not find symbol '%s' in loaded module\n", sym_name);
    return sym;
}

static int set_param(AVFilterContext *ctx, f0r_param_info_t info, int index, char *param)
{
    Frei0rContext *frei0r = ctx->priv;
    union {
        double d;
        f0r_param_color_t col;
        f0r_param_position_t pos;
    } val;
    char *tail;
    uint8_t rgba[4];

    switch (info.type) {
    case F0R_PARAM_BOOL:
        if      (!strcmp(param, "y")) val.d = 1.0;
        else if (!strcmp(param, "n")) val.d = 0.0;
        else goto fail;
        break;

    case F0R_PARAM_DOUBLE:
        val.d = strtod(param, &tail);
        if (*tail || val.d == HUGE_VAL)
            goto fail;
        break;

    case F0R_PARAM_COLOR:
        if (sscanf(param, "%f/%f/%f", &val.col.r, &val.col.g, &val.col.b) != 3) {
110
            if (av_parse_color(rgba, param, -1, ctx) < 0)
Stefano Sabatini's avatar
Stefano Sabatini committed
111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154
                goto fail;
            val.col.r = rgba[0] / 255.0;
            val.col.g = rgba[1] / 255.0;
            val.col.b = rgba[2] / 255.0;
        }
        break;

    case F0R_PARAM_POSITION:
        if (sscanf(param, "%lf/%lf", &val.pos.x, &val.pos.y) != 2)
            goto fail;
        break;
    }

    frei0r->set_param_value(frei0r->instance, &val, index);
    return 0;

fail:
    av_log(ctx, AV_LOG_ERROR, "Invalid value '%s' for parameter '%s'\n",
           param, info.name);
    return AVERROR(EINVAL);
}

static int set_params(AVFilterContext *ctx, const char *params)
{
    Frei0rContext *frei0r = ctx->priv;
    int i;

    for (i = 0; i < frei0r->plugin_info.num_params; i++) {
        f0r_param_info_t info;
        char *param;
        int ret;

        frei0r->get_param_info(&info, i);

        if (*params) {
            if (!(param = av_get_token(&params, ":")))
                return AVERROR(ENOMEM);
            params++;               /* skip ':' */
            ret = set_param(ctx, info, i, param);
            av_free(param);
            if (ret < 0)
                return ret;
        }

155
        av_log(ctx, AV_LOG_VERBOSE,
Stefano Sabatini's avatar
Stefano Sabatini committed
156 157 158 159 160 161 162 163 164 165
               "idx:%d name:'%s' type:%s explanation:'%s' ",
               i, info.name,
               info.type == F0R_PARAM_BOOL     ? "bool"     :
               info.type == F0R_PARAM_DOUBLE   ? "double"   :
               info.type == F0R_PARAM_COLOR    ? "color"    :
               info.type == F0R_PARAM_POSITION ? "position" :
               info.type == F0R_PARAM_STRING   ? "string"   : "unknown",
               info.explanation);

#ifdef DEBUG
166
        av_log(ctx, AV_LOG_DEBUG, "value:");
Stefano Sabatini's avatar
Stefano Sabatini committed
167 168 169 170 171 172 173 174 175 176
        switch (info.type) {
            void *v;
            double d;
            char s[128];
            f0r_param_color_t col;
            f0r_param_position_t pos;

        case F0R_PARAM_BOOL:
            v = &d;
            frei0r->get_param_value(frei0r->instance, v, i);
177
            av_log(ctx, AV_LOG_DEBUG, "%s", d >= 0.5 && d <= 1.0 ? "y" : "n");
Stefano Sabatini's avatar
Stefano Sabatini committed
178 179 180 181
            break;
        case F0R_PARAM_DOUBLE:
            v = &d;
            frei0r->get_param_value(frei0r->instance, v, i);
182
            av_log(ctx, AV_LOG_DEBUG, "%f", d);
Stefano Sabatini's avatar
Stefano Sabatini committed
183 184 185 186
            break;
        case F0R_PARAM_COLOR:
            v = &col;
            frei0r->get_param_value(frei0r->instance, v, i);
187
            av_log(ctx, AV_LOG_DEBUG, "%f/%f/%f", col.r, col.g, col.b);
Stefano Sabatini's avatar
Stefano Sabatini committed
188 189 190 191
            break;
        case F0R_PARAM_POSITION:
            v = &pos;
            frei0r->get_param_value(frei0r->instance, v, i);
192
            av_log(ctx, AV_LOG_DEBUG, "%lf/%lf", pos.x, pos.y);
Stefano Sabatini's avatar
Stefano Sabatini committed
193 194 195 196
            break;
        default: /* F0R_PARAM_STRING */
            v = s;
            frei0r->get_param_value(frei0r->instance, v, i);
197
            av_log(ctx, AV_LOG_DEBUG, "'%s'\n", s);
Stefano Sabatini's avatar
Stefano Sabatini committed
198 199 200
            break;
        }
#endif
201
        av_log(ctx, AV_LOG_VERBOSE, "\n");
Stefano Sabatini's avatar
Stefano Sabatini committed
202 203 204 205 206 207 208 209 210
    }

    return 0;
}

static void *load_path(AVFilterContext *ctx, const char *prefix, const char *name)
{
    char path[1024];

211
    snprintf(path, sizeof(path), "%s%s%s", prefix, name, SLIBSUF);
Stefano Sabatini's avatar
Stefano Sabatini committed
212 213 214 215
    av_log(ctx, AV_LOG_DEBUG, "Looking for frei0r effect in '%s'\n", path);
    return dlopen(path, RTLD_NOW|RTLD_LOCAL);
}

Stefano Sabatini's avatar
Stefano Sabatini committed
216 217
static av_cold int frei0r_init(AVFilterContext *ctx,
                               const char *dl_name, int type)
Stefano Sabatini's avatar
Stefano Sabatini committed
218 219 220 221 222
{
    Frei0rContext *frei0r = ctx->priv;
    f0r_init_f            f0r_init;
    f0r_get_plugin_info_f f0r_get_plugin_info;
    f0r_plugin_info_t *pi;
Stefano Sabatini's avatar
Stefano Sabatini committed
223
    char *path;
Stefano Sabatini's avatar
Stefano Sabatini committed
224 225 226 227 228 229 230 231 232

    /* see: http://piksel.org/frei0r/1.2/spec/1.2/spec/group__pluglocations.html */
    if ((path = av_strdup(getenv("FREI0R_PATH")))) {
        char *p, *ptr = NULL;
        for (p = path; p = strtok_r(p, ":", &ptr); p = NULL)
            if (frei0r->dl_handle = load_path(ctx, p, dl_name))
                break;
        av_free(path);
    }
233
    if (!frei0r->dl_handle && (path = getenv("HOME"))) {
Stefano Sabatini's avatar
Stefano Sabatini committed
234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264
        char prefix[1024];
        snprintf(prefix, sizeof(prefix), "%s/.frei0r-1/lib/", path);
        frei0r->dl_handle = load_path(ctx, prefix, dl_name);
    }
    if (!frei0r->dl_handle)
        frei0r->dl_handle = load_path(ctx, "/usr/local/lib/frei0r-1/", dl_name);
    if (!frei0r->dl_handle)
        frei0r->dl_handle = load_path(ctx, "/usr/lib/frei0r-1/", dl_name);
    if (!frei0r->dl_handle) {
        av_log(ctx, AV_LOG_ERROR, "Could not find module '%s'\n", dl_name);
        return AVERROR(EINVAL);
    }

    if (!(f0r_init                = load_sym(ctx, "f0r_init"           )) ||
        !(f0r_get_plugin_info     = load_sym(ctx, "f0r_get_plugin_info")) ||
        !(frei0r->get_param_info  = load_sym(ctx, "f0r_get_param_info" )) ||
        !(frei0r->get_param_value = load_sym(ctx, "f0r_get_param_value")) ||
        !(frei0r->set_param_value = load_sym(ctx, "f0r_set_param_value")) ||
        !(frei0r->update          = load_sym(ctx, "f0r_update"         )) ||
        !(frei0r->construct       = load_sym(ctx, "f0r_construct"      )) ||
        !(frei0r->destruct        = load_sym(ctx, "f0r_destruct"       )) ||
        !(frei0r->deinit          = load_sym(ctx, "f0r_deinit"         )))
        return AVERROR(EINVAL);

    if (f0r_init() < 0) {
        av_log(ctx, AV_LOG_ERROR, "Could not init the frei0r module");
        return AVERROR(EINVAL);
    }

    f0r_get_plugin_info(&frei0r->plugin_info);
    pi = &frei0r->plugin_info;
Stefano Sabatini's avatar
Stefano Sabatini committed
265
    if (pi->plugin_type != type) {
Stefano Sabatini's avatar
Stefano Sabatini committed
266
        av_log(ctx, AV_LOG_ERROR,
Stefano Sabatini's avatar
Stefano Sabatini committed
267 268
               "Invalid type '%s' for the plugin\n",
               pi->plugin_type == F0R_PLUGIN_TYPE_FILTER ? "filter" :
Stefano Sabatini's avatar
Stefano Sabatini committed
269 270 271 272 273 274
               pi->plugin_type == F0R_PLUGIN_TYPE_SOURCE ? "source" :
               pi->plugin_type == F0R_PLUGIN_TYPE_MIXER2 ? "mixer2" :
               pi->plugin_type == F0R_PLUGIN_TYPE_MIXER3 ? "mixer3" : "unknown");
        return AVERROR(EINVAL);
    }

275
    av_log(ctx, AV_LOG_VERBOSE,
Stefano Sabatini's avatar
Stefano Sabatini committed
276 277 278 279 280 281 282 283 284 285 286
           "name:%s author:'%s' explanation:'%s' color_model:%s "
           "frei0r_version:%d version:%d.%d num_params:%d\n",
           pi->name, pi->author, pi->explanation,
           pi->color_model == F0R_COLOR_MODEL_BGRA8888 ? "bgra8888" :
           pi->color_model == F0R_COLOR_MODEL_RGBA8888 ? "rgba8888" :
           pi->color_model == F0R_COLOR_MODEL_PACKED32 ? "packed32" : "unknown",
           pi->frei0r_version, pi->major_version, pi->minor_version, pi->num_params);

    return 0;
}

287
static av_cold int filter_init(AVFilterContext *ctx, const char *args)
Stefano Sabatini's avatar
Stefano Sabatini committed
288 289
{
    Frei0rContext *frei0r = ctx->priv;
290
    char dl_name[1024], c;
Stefano Sabatini's avatar
Stefano Sabatini committed
291 292 293
    *frei0r->params = 0;

    if (args)
294
        sscanf(args, "%1023[^:=]%c%255c", dl_name, &c, frei0r->params);
Stefano Sabatini's avatar
Stefano Sabatini committed
295 296 297 298

    return frei0r_init(ctx, dl_name, F0R_PLUGIN_TYPE_FILTER);
}

Stefano Sabatini's avatar
Stefano Sabatini committed
299 300 301 302
static av_cold void uninit(AVFilterContext *ctx)
{
    Frei0rContext *frei0r = ctx->priv;

Stefano Sabatini's avatar
Stefano Sabatini committed
303
    if (frei0r->destruct && frei0r->instance)
Stefano Sabatini's avatar
Stefano Sabatini committed
304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331
        frei0r->destruct(frei0r->instance);
    if (frei0r->deinit)
        frei0r->deinit();
    if (frei0r->dl_handle)
        dlclose(frei0r->dl_handle);

    memset(frei0r, 0, sizeof(*frei0r));
}

static int config_input_props(AVFilterLink *inlink)
{
    AVFilterContext *ctx = inlink->dst;
    Frei0rContext *frei0r = ctx->priv;

    if (!(frei0r->instance = frei0r->construct(inlink->w, inlink->h))) {
        av_log(ctx, AV_LOG_ERROR, "Impossible to load frei0r instance");
        return AVERROR(EINVAL);
    }

    return set_params(ctx, frei0r->params);
}

static int query_formats(AVFilterContext *ctx)
{
    Frei0rContext *frei0r = ctx->priv;
    AVFilterFormats *formats = NULL;

    if        (frei0r->plugin_info.color_model == F0R_COLOR_MODEL_BGRA8888) {
332
        ff_add_format(&formats, PIX_FMT_BGRA);
Stefano Sabatini's avatar
Stefano Sabatini committed
333
    } else if (frei0r->plugin_info.color_model == F0R_COLOR_MODEL_RGBA8888) {
334
        ff_add_format(&formats, PIX_FMT_RGBA);
Stefano Sabatini's avatar
Stefano Sabatini committed
335 336 337 338
    } else {                                   /* F0R_COLOR_MODEL_PACKED32 */
        static const enum PixelFormat pix_fmts[] = {
            PIX_FMT_BGRA, PIX_FMT_ARGB, PIX_FMT_ABGR, PIX_FMT_ARGB, PIX_FMT_NONE
        };
339
        formats = ff_make_format_list(pix_fmts);
Stefano Sabatini's avatar
Stefano Sabatini committed
340 341 342 343 344
    }

    if (!formats)
        return AVERROR(ENOMEM);

345
    ff_set_common_formats(ctx, formats);
Stefano Sabatini's avatar
Stefano Sabatini committed
346 347 348
    return 0;
}

349 350 351 352
static int null_draw_slice(AVFilterLink *inlink, int y, int h, int slice_dir)
{
    return 0;
}
Stefano Sabatini's avatar
Stefano Sabatini committed
353

354
static int end_frame(AVFilterLink *inlink)
Stefano Sabatini's avatar
Stefano Sabatini committed
355 356 357 358 359
{
    Frei0rContext *frei0r = inlink->dst->priv;
    AVFilterLink *outlink = inlink->dst->outputs[0];
    AVFilterBufferRef  *inpicref =  inlink->cur_buf;
    AVFilterBufferRef *outpicref = outlink->out_buf;
360
    int ret;
Stefano Sabatini's avatar
Stefano Sabatini committed
361

362
    frei0r->update(frei0r->instance, inpicref->pts * av_q2d(inlink->time_base) * 1000,
Stefano Sabatini's avatar
Stefano Sabatini committed
363 364
                   (const uint32_t *)inpicref->data[0],
                   (uint32_t *)outpicref->data[0]);
365 366 367 368
    if ((ret = ff_draw_slice(outlink, 0, outlink->h, 1)) ||
        (ret = ff_end_frame(outlink)) < 0)
        return ret;
    return 0;
Stefano Sabatini's avatar
Stefano Sabatini committed
369 370 371 372 373 374 375
}

AVFilter avfilter_vf_frei0r = {
    .name      = "frei0r",
    .description = NULL_IF_CONFIG_SMALL("Apply a frei0r effect."),

    .query_formats = query_formats,
Stefano Sabatini's avatar
Stefano Sabatini committed
376
    .init = filter_init,
Stefano Sabatini's avatar
Stefano Sabatini committed
377 378 379 380
    .uninit = uninit,

    .priv_size = sizeof(Frei0rContext),

381 382 383 384 385 386 387 388 389 390 391
    .inputs    = (const AVFilterPad[]) {{ .name             = "default",
                                          .type             = AVMEDIA_TYPE_VIDEO,
                                          .draw_slice       = null_draw_slice,
                                          .config_props     = config_input_props,
                                          .end_frame        = end_frame,
                                          .min_perms        = AV_PERM_READ },
                                        { .name = NULL}},

    .outputs   = (const AVFilterPad[]) {{ .name             = "default",
                                          .type             = AVMEDIA_TYPE_VIDEO, },
                                        { .name = NULL}},
Stefano Sabatini's avatar
Stefano Sabatini committed
392
};
Stefano Sabatini's avatar
Stefano Sabatini committed
393

394
static av_cold int source_init(AVFilterContext *ctx, const char *args)
Stefano Sabatini's avatar
Stefano Sabatini committed
395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445
{
    Frei0rContext *frei0r = ctx->priv;
    char dl_name[1024], c;
    char frame_size[128] = "";
    char frame_rate[128] = "";
    AVRational frame_rate_q;

    memset(frei0r->params, 0, sizeof(frei0r->params));

    if (args)
        sscanf(args, "%127[^:]:%127[^:]:%1023[^:=]%c%255c",
               frame_size, frame_rate, dl_name, &c, frei0r->params);

    if (av_parse_video_size(&frei0r->w, &frei0r->h, frame_size) < 0) {
        av_log(ctx, AV_LOG_ERROR, "Invalid frame size: '%s'\n", frame_size);
        return AVERROR(EINVAL);
    }

    if (av_parse_video_rate(&frame_rate_q, frame_rate) < 0 ||
        frame_rate_q.den <= 0 || frame_rate_q.num <= 0) {
        av_log(ctx, AV_LOG_ERROR, "Invalid frame rate: '%s'\n", frame_rate);
        return AVERROR(EINVAL);
    }
    frei0r->time_base.num = frame_rate_q.den;
    frei0r->time_base.den = frame_rate_q.num;

    return frei0r_init(ctx, dl_name, F0R_PLUGIN_TYPE_SOURCE);
}

static int source_config_props(AVFilterLink *outlink)
{
    AVFilterContext *ctx = outlink->src;
    Frei0rContext *frei0r = ctx->priv;

    if (av_image_check_size(frei0r->w, frei0r->h, 0, ctx) < 0)
        return AVERROR(EINVAL);
    outlink->w = frei0r->w;
    outlink->h = frei0r->h;
    outlink->time_base = frei0r->time_base;

    if (!(frei0r->instance = frei0r->construct(outlink->w, outlink->h))) {
        av_log(ctx, AV_LOG_ERROR, "Impossible to load frei0r instance");
        return AVERROR(EINVAL);
    }

    return set_params(ctx, frei0r->params);
}

static int source_request_frame(AVFilterLink *outlink)
{
    Frei0rContext *frei0r = outlink->src->priv;
446
    AVFilterBufferRef *picref = ff_get_video_buffer(outlink, AV_PERM_WRITE, outlink->w, outlink->h);
447
    AVFilterBufferRef *buf_out;
448 449
    int ret;

450 451 452
    if (!picref)
        return AVERROR(ENOMEM);

Stefano Sabatini's avatar
Stefano Sabatini committed
453 454 455 456
    picref->video->pixel_aspect = (AVRational) {1, 1};
    picref->pts = frei0r->pts++;
    picref->pos = -1;

457 458 459 460 461 462 463
    buf_out = avfilter_ref_buffer(picref, ~0);
    if (!buf_out) {
        ret = AVERROR(ENOMEM);
        goto fail;
    }

    ret = ff_start_frame(outlink, buf_out);
464 465 466
    if (ret < 0)
        goto fail;

Stefano Sabatini's avatar
Stefano Sabatini committed
467 468
    frei0r->update(frei0r->instance, av_rescale_q(picref->pts, frei0r->time_base, (AVRational){1,1000}),
                   NULL, (uint32_t *)picref->data[0]);
469 470 471 472 473 474 475
    ret = ff_draw_slice(outlink, 0, outlink->h, 1);
    if (ret < 0)
        goto fail;

    ret = ff_end_frame(outlink);

fail:
Stefano Sabatini's avatar
Stefano Sabatini committed
476 477
    avfilter_unref_buffer(picref);

478
    return ret;
Stefano Sabatini's avatar
Stefano Sabatini committed
479 480 481 482 483 484 485 486 487 488 489 490
}

AVFilter avfilter_vsrc_frei0r_src = {
    .name        = "frei0r_src",
    .description = NULL_IF_CONFIG_SMALL("Generate a frei0r source."),

    .priv_size = sizeof(Frei0rContext),
    .init      = source_init,
    .uninit    = uninit,

    .query_formats = query_formats,

491
    .inputs    = (const AVFilterPad[]) {{ .name = NULL}},
Stefano Sabatini's avatar
Stefano Sabatini committed
492

493 494 495 496 497
    .outputs   = (const AVFilterPad[]) {{ .name            = "default",
                                          .type            = AVMEDIA_TYPE_VIDEO,
                                          .request_frame   = source_request_frame,
                                          .config_props    = source_config_props },
                                        { .name = NULL}},
Stefano Sabatini's avatar
Stefano Sabatini committed
498
};