gstreamer/subprojects/gst-plugins-bad/sys/androidmedia/jni/gstamc-jni.c
Ratchanan Srirattanamet d0ffcb46df androidmedia: call all static_init() functions from single entry point
This allows the implementations to do custom logic behind the hood. For
example, when NDK implementation is added, the entrypoint can chooses to
statically initialize the NDK implementations or the JNI one.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4115>
2024-01-11 19:00:13 +00:00

39 lines
1.1 KiB
C

/*
* Copyright (C) 2023, Ratchanan Srirattanamet <peathot@hotmail.com>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation
* version 2.1 of the License.
*
* This library 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
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*
*/
#include "../gstamc.h"
#include "gstamc-jni.h"
gboolean
gst_amc_static_init (void)
{
if (!gst_amc_codeclist_jni_static_init ())
return FALSE;
if (!gst_amc_codec_jni_static_init ())
return FALSE;
if (!gst_amc_format_jni_static_init ())
return FALSE;
if (!gst_amc_surface_texture_jni_static_init ())
return FALSE;
return TRUE;
}