コード例 #1
0
ファイル: gstenumtypes.c プロジェクト: AlerIl/gstreamer0.10
/* enumerations from "gstdebugutils.h" */
GType
gst_debug_graph_details_get_type (void)
{
  static gsize id = 0;
  static const GFlagsValue values[] = {
    {C_FLAGS (GST_DEBUG_GRAPH_SHOW_MEDIA_TYPE),
        "GST_DEBUG_GRAPH_SHOW_MEDIA_TYPE", "media-type"},
    {C_FLAGS (GST_DEBUG_GRAPH_SHOW_CAPS_DETAILS),
        "GST_DEBUG_GRAPH_SHOW_CAPS_DETAILS", "caps-details"},
    {C_FLAGS (GST_DEBUG_GRAPH_SHOW_NON_DEFAULT_PARAMS),
        "GST_DEBUG_GRAPH_SHOW_NON_DEFAULT_PARAMS", "non-default-params"},
    {C_FLAGS (GST_DEBUG_GRAPH_SHOW_STATES), "GST_DEBUG_GRAPH_SHOW_STATES",
        "states"},
    {C_FLAGS (GST_DEBUG_GRAPH_SHOW_ALL), "GST_DEBUG_GRAPH_SHOW_ALL", "all"},
    {0, NULL, NULL}
  };

  if (g_once_init_enter (&id)) {
    GType tmp = g_flags_register_static ("GstDebugGraphDetails", values);
    g_once_init_leave (&id, tmp);
  }

  return (GType) id;
}
コード例 #2
0
ファイル: gstenumtypes.c プロジェクト: AlerIl/gstreamer0.10
GType
gst_flow_return_get_type (void)
{
  static gsize id = 0;
  static const GEnumValue values[] = {
    {C_ENUM (GST_FLOW_CUSTOM_SUCCESS_2), "GST_FLOW_CUSTOM_SUCCESS_2",
        "custom-success-2"},
    {C_ENUM (GST_FLOW_CUSTOM_SUCCESS_1), "GST_FLOW_CUSTOM_SUCCESS_1",
        "custom-success-1"},
    {C_ENUM (GST_FLOW_CUSTOM_SUCCESS), "GST_FLOW_CUSTOM_SUCCESS",
        "custom-success"},
    {C_ENUM (GST_FLOW_RESEND), "GST_FLOW_RESEND", "resend"},
    {C_ENUM (GST_FLOW_OK), "GST_FLOW_OK", "ok"},
    {C_ENUM (GST_FLOW_NOT_LINKED), "GST_FLOW_NOT_LINKED", "not-linked"},
    {C_ENUM (GST_FLOW_WRONG_STATE), "GST_FLOW_WRONG_STATE", "wrong-state"},
    {C_ENUM (GST_FLOW_UNEXPECTED), "GST_FLOW_UNEXPECTED", "unexpected"},
    {C_ENUM (GST_FLOW_NOT_NEGOTIATED), "GST_FLOW_NOT_NEGOTIATED",
        "not-negotiated"},
    {C_ENUM (GST_FLOW_ERROR), "GST_FLOW_ERROR", "error"},
    {C_ENUM (GST_FLOW_NOT_SUPPORTED), "GST_FLOW_NOT_SUPPORTED",
        "not-supported"},
    {C_ENUM (GST_FLOW_CUSTOM_ERROR), "GST_FLOW_CUSTOM_ERROR", "custom-error"},
    {C_ENUM (GST_FLOW_CUSTOM_ERROR_1), "GST_FLOW_CUSTOM_ERROR_1",
        "custom-error-1"},
    {C_ENUM (GST_FLOW_CUSTOM_ERROR_2), "GST_FLOW_CUSTOM_ERROR_2",
        "custom-error-2"},
    {0, NULL, NULL}
  };

  if (g_once_init_enter (&id)) {
    GType tmp = g_enum_register_static ("GstFlowReturn", values);
    g_once_init_leave (&id, tmp);
  }

  return (GType) id;
}
コード例 #3
0
ファイル: gstenumtypes.c プロジェクト: AlerIl/gstreamer0.10
/* enumerations from "gsttaglist.h" */
GType
gst_tag_merge_mode_get_type (void)
{
  static gsize id = 0;
  static const GEnumValue values[] = {
    {C_ENUM (GST_TAG_MERGE_UNDEFINED), "GST_TAG_MERGE_UNDEFINED", "undefined"},
    {C_ENUM (GST_TAG_MERGE_REPLACE_ALL), "GST_TAG_MERGE_REPLACE_ALL",
        "replace-all"},
    {C_ENUM (GST_TAG_MERGE_REPLACE), "GST_TAG_MERGE_REPLACE", "replace"},
    {C_ENUM (GST_TAG_MERGE_APPEND), "GST_TAG_MERGE_APPEND", "append"},
    {C_ENUM (GST_TAG_MERGE_PREPEND), "GST_TAG_MERGE_PREPEND", "prepend"},
    {C_ENUM (GST_TAG_MERGE_KEEP), "GST_TAG_MERGE_KEEP", "keep"},
    {C_ENUM (GST_TAG_MERGE_KEEP_ALL), "GST_TAG_MERGE_KEEP_ALL", "keep-all"},
    {C_ENUM (GST_TAG_MERGE_COUNT), "GST_TAG_MERGE_COUNT", "count"},
    {0, NULL, NULL}
  };

  if (g_once_init_enter (&id)) {
    GType tmp = g_enum_register_static ("GstTagMergeMode", values);
    g_once_init_leave (&id, tmp);
  }

  return (GType) id;
}
コード例 #4
0
ファイル: gstcontroller.c プロジェクト: genesi/gstreamer
GType
gst_controller_get_type (void)
{
  static volatile gsize type = 0;

  if (g_once_init_enter (&type)) {
    GType _type;
    static const GTypeInfo info = {
      sizeof (GstControllerClass),
      NULL,                     /* base_init */
      NULL,                     /* base_finalize */
      (GClassInitFunc) _gst_controller_class_init,      /* class_init */
      NULL,                     /* class_finalize */
      NULL,                     /* class_data */
      sizeof (GstController),
      0,                        /* n_preallocs */
      (GInstanceInitFunc) _gst_controller_init, /* instance_init */
      NULL                      /* value_table */
    };
    _type = g_type_register_static (G_TYPE_OBJECT, "GstController", &info, 0);
    g_once_init_leave (&type, _type);
  }
  return type;
}
コード例 #5
0
ファイル: gstenumtypes.c プロジェクト: AlerIl/gstreamer0.10
/* enumerations from "gstpad.h" */
GType
gst_pad_link_return_get_type (void)
{
  static gsize id = 0;
  static const GEnumValue values[] = {
    {C_ENUM (GST_PAD_LINK_OK), "GST_PAD_LINK_OK", "ok"},
    {C_ENUM (GST_PAD_LINK_WRONG_HIERARCHY), "GST_PAD_LINK_WRONG_HIERARCHY",
        "wrong-hierarchy"},
    {C_ENUM (GST_PAD_LINK_WAS_LINKED), "GST_PAD_LINK_WAS_LINKED", "was-linked"},
    {C_ENUM (GST_PAD_LINK_WRONG_DIRECTION), "GST_PAD_LINK_WRONG_DIRECTION",
        "wrong-direction"},
    {C_ENUM (GST_PAD_LINK_NOFORMAT), "GST_PAD_LINK_NOFORMAT", "noformat"},
    {C_ENUM (GST_PAD_LINK_NOSCHED), "GST_PAD_LINK_NOSCHED", "nosched"},
    {C_ENUM (GST_PAD_LINK_REFUSED), "GST_PAD_LINK_REFUSED", "refused"},
    {0, NULL, NULL}
  };

  if (g_once_init_enter (&id)) {
    GType tmp = g_enum_register_static ("GstPadLinkReturn", values);
    g_once_init_leave (&id, tmp);
  }

  return (GType) id;
}
コード例 #6
0
GType
cogl_blend_string_error_get_type (void)
{
  static volatile gsize g_enum_type_id__volatile = 0;

  if (g_once_init_enter (&g_enum_type_id__volatile))
    {
      static const GEnumValue values[] = {
        { COGL_BLEND_STRING_ERROR_PARSE_ERROR, "COGL_BLEND_STRING_ERROR_PARSE_ERROR", "parse-error" },
        { COGL_BLEND_STRING_ERROR_ARGUMENT_PARSE_ERROR, "COGL_BLEND_STRING_ERROR_ARGUMENT_PARSE_ERROR", "argument-parse-error" },
        { COGL_BLEND_STRING_ERROR_INVALID_ERROR, "COGL_BLEND_STRING_ERROR_INVALID_ERROR", "invalid-error" },
        { COGL_BLEND_STRING_ERROR_GPU_UNSUPPORTED_ERROR, "COGL_BLEND_STRING_ERROR_GPU_UNSUPPORTED_ERROR", "gpu-unsupported-error" },
        { 0, NULL, NULL }
      };
      GType g_enum_type_id;

      g_enum_type_id =
        g_enum_register_static (g_intern_static_string ("CoglBlendStringError"), values);

      g_once_init_leave (&g_enum_type_id__volatile, g_enum_type_id);
    }

  return g_enum_type_id__volatile;
}
コード例 #7
0
ファイル: mex-main.c プロジェクト: ocrete/media-explorer
static void
mex_base_init (int *argc, char ***argv)
{
  static gsize initialised;

  if (g_once_init_enter (&initialised))
    {
      /* initialize debugging infrastructure */
      _mex_log_init_core_domains ();

      /* initialise Clutter */
      if (!clutter_init (argc, argv))
        g_error ("Failed to initialize clutter");

#ifdef USE_PLAYER_CLUTTER_GST
      clutter_gst_init (argc, argv);
#endif

      mex_init_default_categories ();
      mex_init_load_grilo_plugins();

      g_once_init_leave (&initialised, TRUE);
    }
}
コード例 #8
0
GType
cogl_texture_flags_get_type (void)
{
  static volatile gsize g_enum_type_id__volatile = 0;

  if (g_once_init_enter (&g_enum_type_id__volatile))
    {
      static const GFlagsValue values[] = {
        { COGL_TEXTURE_NONE, "COGL_TEXTURE_NONE", "none" },
        { COGL_TEXTURE_NO_AUTO_MIPMAP, "COGL_TEXTURE_NO_AUTO_MIPMAP", "no-auto-mipmap" },
        { COGL_TEXTURE_NO_SLICING, "COGL_TEXTURE_NO_SLICING", "no-slicing" },
        { COGL_TEXTURE_NO_ATLAS, "COGL_TEXTURE_NO_ATLAS", "no-atlas" },
        { 0, NULL, NULL }
      };
      GType g_enum_type_id;

      g_enum_type_id =
        g_flags_register_static (g_intern_static_string ("CoglTextureFlags"), values);

      g_once_init_leave (&g_enum_type_id__volatile, g_enum_type_id);
    }

  return g_enum_type_id__volatile;
}
コード例 #9
0
GType
cogl_texture_error_get_type (void)
{
  static volatile gsize g_enum_type_id__volatile = 0;

  if (g_once_init_enter (&g_enum_type_id__volatile))
    {
      static const GEnumValue values[] = {
        { COGL_TEXTURE_ERROR_SIZE, "COGL_TEXTURE_ERROR_SIZE", "size" },
        { COGL_TEXTURE_ERROR_FORMAT, "COGL_TEXTURE_ERROR_FORMAT", "format" },
        { COGL_TEXTURE_ERROR_BAD_PARAMETER, "COGL_TEXTURE_ERROR_BAD_PARAMETER", "bad-parameter" },
        { COGL_TEXTURE_ERROR_TYPE, "COGL_TEXTURE_ERROR_TYPE", "type" },
        { 0, NULL, NULL }
      };
      GType g_enum_type_id;

      g_enum_type_id =
        g_enum_register_static (g_intern_static_string ("CoglTextureError"), values);

      g_once_init_leave (&g_enum_type_id__volatile, g_enum_type_id);
    }

  return g_enum_type_id__volatile;
}
static GType
gst_vp8_enc_tune_get_type (void)
{
  static const GEnumValue values[] = {
#ifdef HAVE_VP8ENC_TUNING
    {VP8_TUNE_PSNR, "Tune for PSNR", "psnr"},
    {VP8_TUNE_SSIM, "Tune for SSIM", "ssim"},
#else
    {VP8_TUNE_NONE, "none", "none"},
#endif
    {0, NULL, NULL}
  };
  static volatile GType id = 0;

  if (g_once_init_enter ((gsize *) & id)) {
    GType _id;

    _id = g_enum_register_static ("GstVP8EncTune", values);

    g_once_init_leave ((gsize *) & id, _id);
  }

  return id;
}
コード例 #11
0
ファイル: gstenumtypes.c プロジェクト: AlerIl/gstreamer0.10
GType
gst_stream_error_get_type (void)
{
  static gsize id = 0;
  static const GEnumValue values[] = {
    {C_ENUM (GST_STREAM_ERROR_FAILED), "GST_STREAM_ERROR_FAILED", "failed"},
    {C_ENUM (GST_STREAM_ERROR_TOO_LAZY), "GST_STREAM_ERROR_TOO_LAZY",
        "too-lazy"},
    {C_ENUM (GST_STREAM_ERROR_NOT_IMPLEMENTED),
        "GST_STREAM_ERROR_NOT_IMPLEMENTED", "not-implemented"},
    {C_ENUM (GST_STREAM_ERROR_TYPE_NOT_FOUND),
        "GST_STREAM_ERROR_TYPE_NOT_FOUND", "type-not-found"},
    {C_ENUM (GST_STREAM_ERROR_WRONG_TYPE), "GST_STREAM_ERROR_WRONG_TYPE",
        "wrong-type"},
    {C_ENUM (GST_STREAM_ERROR_CODEC_NOT_FOUND),
        "GST_STREAM_ERROR_CODEC_NOT_FOUND", "codec-not-found"},
    {C_ENUM (GST_STREAM_ERROR_DECODE), "GST_STREAM_ERROR_DECODE", "decode"},
    {C_ENUM (GST_STREAM_ERROR_ENCODE), "GST_STREAM_ERROR_ENCODE", "encode"},
    {C_ENUM (GST_STREAM_ERROR_DEMUX), "GST_STREAM_ERROR_DEMUX", "demux"},
    {C_ENUM (GST_STREAM_ERROR_MUX), "GST_STREAM_ERROR_MUX", "mux"},
    {C_ENUM (GST_STREAM_ERROR_FORMAT), "GST_STREAM_ERROR_FORMAT", "format"},
    {C_ENUM (GST_STREAM_ERROR_DECRYPT), "GST_STREAM_ERROR_DECRYPT", "decrypt"},
    {C_ENUM (GST_STREAM_ERROR_DECRYPT_NOKEY), "GST_STREAM_ERROR_DECRYPT_NOKEY",
        "decrypt-nokey"},
    {C_ENUM (GST_STREAM_ERROR_NUM_ERRORS), "GST_STREAM_ERROR_NUM_ERRORS",
        "num-errors"},
    {0, NULL, NULL}
  };

  if (g_once_init_enter (&id)) {
    GType tmp = g_enum_register_static ("GstStreamError", values);
    g_once_init_leave (&id, tmp);
  }

  return (GType) id;
}
コード例 #12
0
GType
@[email protected]_get_type (void)
{
  static volatile gsize g_define_type_id__volatile = 0;

  if (g_once_init_enter (&g_define_type_id__volatile))
    {
      static const [email protected]@Value values[] = {
/*** END value-header ***/

/*** BEGIN value-production ***/
        { @[email protected], "@[email protected]", "@[email protected]" },
/*** END value-production ***/

/*** BEGIN value-tail ***/
        { 0, NULL, NULL }
      };
      GType g_define_type_id =
        [email protected]@_register_static (g_intern_static_string ("@[email protected]"), values);
      g_once_init_leave (&g_define_type_id__volatile, g_define_type_id);
    }

  return g_define_type_id__volatile;
}
コード例 #13
0
ファイル: poppler-enums.c プロジェクト: Sektor/qtmoko-apps
GType
poppler_page_layout_get_type (void)
{
  static volatile gsize g_define_type_id__volatile = 0;
 
  if (g_once_init_enter (&g_define_type_id__volatile)) {
    static const GEnumValue values[] = {
      { POPPLER_PAGE_LAYOUT_UNSET, "POPPLER_PAGE_LAYOUT_UNSET", "unset" },
      { POPPLER_PAGE_LAYOUT_SINGLE_PAGE, "POPPLER_PAGE_LAYOUT_SINGLE_PAGE", "single-page" },
      { POPPLER_PAGE_LAYOUT_ONE_COLUMN, "POPPLER_PAGE_LAYOUT_ONE_COLUMN", "one-column" },
      { POPPLER_PAGE_LAYOUT_TWO_COLUMN_LEFT, "POPPLER_PAGE_LAYOUT_TWO_COLUMN_LEFT", "two-column-left" },
      { POPPLER_PAGE_LAYOUT_TWO_COLUMN_RIGHT, "POPPLER_PAGE_LAYOUT_TWO_COLUMN_RIGHT", "two-column-right" },
      { POPPLER_PAGE_LAYOUT_TWO_PAGE_LEFT, "POPPLER_PAGE_LAYOUT_TWO_PAGE_LEFT", "two-page-left" },
      { POPPLER_PAGE_LAYOUT_TWO_PAGE_RIGHT, "POPPLER_PAGE_LAYOUT_TWO_PAGE_RIGHT", "two-page-right" },
      { 0, NULL, NULL }
    };
    GType g_define_type_id = 
       g_enum_register_static (g_intern_static_string ("PopplerPageLayout"), values);
      
    g_once_init_leave (&g_define_type_id__volatile, g_define_type_id);
  }
    
  return g_define_type_id__volatile;
}
コード例 #14
0
GType hls_progress_buffer_get_type (void)
{
    static volatile gsize gonce_data = 0;
// INLINE - g_once_init_enter()
    if (g_once_init_enter (&gonce_data))
    {
        GType _type;
        _type = gst_type_register_static_full (GST_TYPE_ELEMENT,
            g_intern_static_string ("HLSProgressBuffer"),
            sizeof (HLSProgressBufferClass),
            hls_progress_buffer_base_init,
            NULL,
            hls_progress_buffer_class_init_trampoline,
            NULL,
            NULL,
            sizeof (HLSProgressBuffer),
            0,
            (GInstanceInitFunc) hls_progress_buffer_init,
            NULL,
            (GTypeFlags) 0);
        g_once_init_leave (&gonce_data, (gsize) _type);
    }
    return (GType) gonce_data;
}
コード例 #15
0
/** Get GType for GSM errors */
GType
modem_sms_net_error_get_type (void)
{
  static const GEnumValue values[] = {
#define _(x, t) { MODEM_SMS_NET_ERROR_ ## x, "MODEM_SMS_NET_ERROR_" #x, #t }
    _(SUCCESS,                          Success),
    _(UNASSIGNED_NUMBER,                UnassignedNumber),
    _(OPER_DETERMINED_BARR,             OperatorDeterminedBarring),
    _(CALL_BARRED,                      CallBarred),
    _(RESERVED,                         Reserved),
    _(MSG_TRANSFER_REJ,                 MessageTransferRejected),
    _(MEMORY_CAPACITY_EXC,              MemoryCapacityExceeded),
    _(DEST_OUT_OF_ORDER,                DestinationOutOfOrder),
    _(UNDEFINED_SUBSCRIBER,             UndefinedSubscriber),
    _(FACILITY_REJECTED,                FacilityRejected),
    _(UNKNOWN_SUBSCRIBER,               UnknownSubscriber),
    _(NETWORK_OUT_OF_ORDER,             NetworkOutOfOrder),
    _(TEMPORARY_FAILURE,                TemporaryFailure),
    _(CONGESTION,                       Congestion),
    _(RESOURCE_UNAVAILABLE,             ResourceUnavailable),
    _(REQ_FACILITY_NOT_SUB,             RequiredFacilityNotSubscribed),
    _(REQ_FACILITY_NOT_IMP,             RequiredFacilityNotImplemented),
    _(INVALID_REFERENCE,                InvalidReferenceValue),
    _(INVALID_MSG,                      InvalidMessage),
    _(INVALID_MAND_IE,                  InvalidMandatoryInfoElement),
    _(INVALID_MSG_TYPE,                 InvalidMessageType),
    _(INCOMPATIBLE_MSG_TYPE,            IncompatibleMessageType),
    _(INVALID_IE_TYPE,                  InvalidInfoElementType),
    _(PROTOCOL_ERROR,                   ProtocolError),
    _(INTERWORKING,                     InterworkingError),
    _(LOW_LAYER_NO_CAUSE,               LowLayerUnknown),
    _(IMSI_UNKNOWN_HLR,                 IMSIUnknownInHLR),
    _(ILLEGAL_MS,                       IllegalMS),
    _(IMSI_UNKNOWN_VLR,                 IMSIUnknownInVLR),
    _(IMEI_NOT_ACCEPTED,                IMEINotAccepted),
    _(ILLEGAL_ME,                       IllegalME),
    _(PLMN_NOT_ALLOWED,                 PLMNNotAllowed),
    _(LA_NOT_ALLOWED,                   LocationAreaNotAllowed),
    _(ROAM_NOT_ALLOWED_LA,              RoamingNotAllowedInThisLocationArea),
    _(NO_SUITABLE_CELLS_LA,             NoSuitableCellsInThisLocationArea),
    _(NETWORK_FAILURE,                  NetworkFailure),
    _(MAC_FAILURE,                      MacFailure),
    _(SYNC_FAILURE,                     SyncFailure),
    _(LOW_LAYER_CONGESTION,             LowLayerCongestion),
    _(AUTH_UNACCEPTABLE,                AuthUnacceptable),
    _(SERV_OPT_NOT_SUPPORTED,           ServiceOptionNotSupported),
    _(SERV_OPT_NOT_SUBSCRIBED,          ServiceOptionNotSubscribed),
    _(SERV_OPT_TEMP_OUT_OF_ORDER,       ServiceOptionTemporarilyOutOfOrder),
    _(CALL_CANNOT_BE_IDENTIFIED,        CallCannotBeIdentified),
    _(LOW_LAYER_INVALID_MSG,            LowLayerInvalidMessage),
    _(LOW_LAYER_INVALID_MAND_IE,        LowLayerInvalidMandatoryInfoElement),
    _(LOW_LAYER_INVALID_MSG_TYPE,       LowLayerInvalidMessageType),
    _(LOW_LAYER_INCOMPATIBLE_MSG_TYPE,  LowLayerIncompatibleMessageType),
    _(LOW_LAYER_INVALID_IE_TYPE,        LowLayerInvalidIEType),
    _(LOW_LAYER_INVALID_IE,             LowLayerInvalidIE),
    _(LOW_LAYER_INCOMPATIBLE_MSG,       LowLayerIncompatibleMessage),
    _(CS_BARRED,                        CSBarred),
    _(LOW_LAYER_PROTOCOL_ERROR,         LowLayerProtocolError),
#undef _
    { 0, NULL, NULL },
  };

  static gsize etype = 0;

  if (g_once_init_enter (&etype))
    {
      GType type = g_enum_register_static ("ModemSmsNetError", values);
      g_once_init_leave (&etype, type);
    }

  return (GType)etype;
}
コード例 #16
0
/** Get GType for network errors */
GType
modem_call_net_error_get_type (void)
{
  static const GEnumValue values[] = {
#define _(x, t) { MODEM_CALL_NET_ERROR_ ## x, "MODEM_CALL_NET_ERROR_" #x, #t }
    _(UNASSIGNED_NUMBER, UnassignedNumber),
    _(NO_ROUTE, NoRouteToDestination),
    _(CH_UNACCEPTABLE, ChannelUnacceptable),
    _(OPER_BARRING, OperatorDeterminedBarring),
    _(NORMAL, NormalCallClearing),
    _(USER_BUSY, UserBusy),
    _(NO_USER_RESPONSE, NoUserResponse),
    _(ALERT_NO_ANSWER, AlertNoAnswer),
    _(CALL_REJECTED, CallRejected),
    _(NUMBER_CHANGED, NumberChanged),
    _(NON_SELECT_CLEAR, NonSelectedClearing),
    _(DEST_OUT_OF_ORDER, DestinationOutOfOrder),
    _(INVALID_NUMBER, InvalidNumber),
    _(FACILITY_REJECTED, FacilityRejected),
    _(RESP_TO_STATUS, ResponseToStatus),
    _(NORMAL_UNSPECIFIED, UnspecifiedNormal),
    _(NO_CHANNEL, NoChannelAvailable),
    _(NETW_OUT_OF_ORDER, NetworkOutOfOrder),
    _(TEMPORARY_FAILURE, TemporaryFailure),
    _(CONGESTION, Congestion),
    _(ACCESS_INFO_DISC, AccessInformationDiscarded),
    _(CHANNEL_NA, ChannelNotAvailable),
    _(RESOURCES_NA, ResourcesNotAvailable),
    _(QOS_NA, QoSNotAvailable),
    _(FACILITY_UNSUBS, RequestedFacilityNotSubscribed),
    _(COMING_BARRED_CUG, IncomingCallsBarredWithinCUG),
    _(BC_UNAUTHORIZED, BearerCapabilityUnauthorized),
    _(BC_NA, BearerCapabilityNotAvailable),
    _(SERVICE_NA, ServiceNotAvailable),
    _(BEARER_NOT_IMPL, BearerNotImplemented),
    _(ACM_MAX, ACMMax),
    _(FACILITY_NOT_IMPL, FacilityNotImplemented),
    _(ONLY_RDI_BC, OnlyRestrictedDIBearerCapability),
    _(SERVICE_NOT_IMPL, ServiceNotImplemented),
    _(INVALID_TI, InvalidTransactionIdentifier),
    _(NOT_IN_CUG, NotInCUG),
    _(INCOMPATIBLE_DEST, IncompatibleDestination),
    _(INV_TRANS_NET_SEL, InvalidTransitNetSelected),
    _(SEMANTICAL_ERR, SemanticalError),
    _(INVALID_MANDATORY, InvalidMandatoryInformation),
    _(MSG_TYPE_INEXIST, MessageTypeNonExistent),
    _(MSG_TYPE_INCOMPAT, MessageTypeIncompatible),
    _(IE_NON_EXISTENT, InformationElementNonExistent),
    _(COND_IE_ERROR, ConditionalInformationElementError),
    _(MSG_INCOMPATIBLE, IncompatibleMessage),
    _(TIMER_EXPIRY, TimerExpiry),
    _(PROTOCOL_ERROR, ProtocolError),
    _(INTERWORKING, Generic),
#undef _
    { 0, NULL, NULL },
  };

  static gsize etype = 0;

  if (g_once_init_enter (&etype))
    {
      GType type = g_enum_register_static ("ModemCallNetError", values);
      g_once_init_leave (&etype, type);
    }

  return (GType)etype;
}
コード例 #17
0
gpointer
gst_gl_context_egl_get_proc_address (GstGLAPI gl_api, const gchar * name)
{
  gpointer result = NULL;
  static GOnce g_once = G_ONCE_INIT;

#ifdef __APPLE__
#if GST_GL_HAVE_OPENGL && !defined(GST_GL_LIBGL_MODULE_NAME)
  if (!result && (gl_api & (GST_GL_API_OPENGL | GST_GL_API_OPENGL3))) {
    static GModule *module_opengl = NULL;
    if (g_once_init_enter (&module_opengl)) {
      GModule *setup_module_opengl =
          g_module_open ("libGL.dylib", G_MODULE_BIND_LAZY);
      g_once_init_leave (&module_opengl, setup_module_opengl);
    }
    if (module_opengl)
      g_module_symbol (module_opengl, name, &result);
  }
#endif
#if GST_GL_HAVE_GLES2 && !defined(GST_GL_LIBGLESV2_MODULE_NAME)
  if (!result && (gl_api & (GST_GL_API_GLES2))) {
    static GModule *module_gles2 = NULL;
    if (g_once_init_enter (&module_gles2)) {
      GModule *setup_module_gles2 =
          g_module_open ("libGLESv2.dylib", G_MODULE_BIND_LAZY);
      g_once_init_leave (&module_gles2, setup_module_gles2);
    }
    if (module_gles2)
      g_module_symbol (module_gles2, name, &result);
  }
#endif
#endif // __APPLE__

  if (!result)
    result = gst_gl_context_default_get_proc_address (gl_api, name);

  g_once (&g_once, load_egl_module, NULL);

  if (!result && module_egl) {
    g_module_symbol (module_egl, name, &result);
  }

  /* FIXME: On Android this returns wrong addresses for non-EGL functions */
#if GST_GL_HAVE_WINDOW_ANDROID
  if (!result && g_str_has_prefix (name, "egl")) {
#else
  if (!result) {
    result = eglGetProcAddress (name);
#endif
  }

  return result;
}

static gboolean
gst_gl_context_egl_check_feature (GstGLContext * context, const gchar * feature)
{
  GstGLContextEGL *context_egl = GST_GL_CONTEXT_EGL (context);

  return gst_gl_check_extension (feature, context_egl->egl_exts);
}
コード例 #18
0
/* enumerations from "video-format.h" */
GType
gst_video_format_get_type (void)
{
  static volatile gsize g_define_type_id__volatile = 0;
  if (g_once_init_enter (&g_define_type_id__volatile)) {
    static const GEnumValue values[] = {
      { GST_VIDEO_FORMAT_UNKNOWN, "GST_VIDEO_FORMAT_UNKNOWN", "unknown" },
      { GST_VIDEO_FORMAT_ENCODED, "GST_VIDEO_FORMAT_ENCODED", "encoded" },
      { GST_VIDEO_FORMAT_I420, "GST_VIDEO_FORMAT_I420", "i420" },
      { GST_VIDEO_FORMAT_YV12, "GST_VIDEO_FORMAT_YV12", "yv12" },
      { GST_VIDEO_FORMAT_YUY2, "GST_VIDEO_FORMAT_YUY2", "yuy2" },
      { GST_VIDEO_FORMAT_UYVY, "GST_VIDEO_FORMAT_UYVY", "uyvy" },
      { GST_VIDEO_FORMAT_AYUV, "GST_VIDEO_FORMAT_AYUV", "ayuv" },
      { GST_VIDEO_FORMAT_RGBx, "GST_VIDEO_FORMAT_RGBx", "rgbx" },
      { GST_VIDEO_FORMAT_BGRx, "GST_VIDEO_FORMAT_BGRx", "bgrx" },
      { GST_VIDEO_FORMAT_xRGB, "GST_VIDEO_FORMAT_xRGB", "xrgb" },
      { GST_VIDEO_FORMAT_xBGR, "GST_VIDEO_FORMAT_xBGR", "xbgr" },
      { GST_VIDEO_FORMAT_RGBA, "GST_VIDEO_FORMAT_RGBA", "rgba" },
      { GST_VIDEO_FORMAT_BGRA, "GST_VIDEO_FORMAT_BGRA", "bgra" },
      { GST_VIDEO_FORMAT_ARGB, "GST_VIDEO_FORMAT_ARGB", "argb" },
      { GST_VIDEO_FORMAT_ABGR, "GST_VIDEO_FORMAT_ABGR", "abgr" },
      { GST_VIDEO_FORMAT_RGB, "GST_VIDEO_FORMAT_RGB", "rgb" },
      { GST_VIDEO_FORMAT_BGR, "GST_VIDEO_FORMAT_BGR", "bgr" },
      { GST_VIDEO_FORMAT_Y41B, "GST_VIDEO_FORMAT_Y41B", "y41b" },
      { GST_VIDEO_FORMAT_Y42B, "GST_VIDEO_FORMAT_Y42B", "y42b" },
      { GST_VIDEO_FORMAT_YVYU, "GST_VIDEO_FORMAT_YVYU", "yvyu" },
      { GST_VIDEO_FORMAT_Y444, "GST_VIDEO_FORMAT_Y444", "y444" },
      { GST_VIDEO_FORMAT_v210, "GST_VIDEO_FORMAT_v210", "v210" },
      { GST_VIDEO_FORMAT_v216, "GST_VIDEO_FORMAT_v216", "v216" },
      { GST_VIDEO_FORMAT_NV12, "GST_VIDEO_FORMAT_NV12", "nv12" },
      { GST_VIDEO_FORMAT_NV21, "GST_VIDEO_FORMAT_NV21", "nv21" },
      { GST_VIDEO_FORMAT_GRAY8, "GST_VIDEO_FORMAT_GRAY8", "gray8" },
      { GST_VIDEO_FORMAT_GRAY16_BE, "GST_VIDEO_FORMAT_GRAY16_BE", "gray16-be" },
      { GST_VIDEO_FORMAT_GRAY16_LE, "GST_VIDEO_FORMAT_GRAY16_LE", "gray16-le" },
      { GST_VIDEO_FORMAT_v308, "GST_VIDEO_FORMAT_v308", "v308" },
      { GST_VIDEO_FORMAT_RGB16, "GST_VIDEO_FORMAT_RGB16", "rgb16" },
      { GST_VIDEO_FORMAT_BGR16, "GST_VIDEO_FORMAT_BGR16", "bgr16" },
      { GST_VIDEO_FORMAT_RGB15, "GST_VIDEO_FORMAT_RGB15", "rgb15" },
      { GST_VIDEO_FORMAT_BGR15, "GST_VIDEO_FORMAT_BGR15", "bgr15" },
      { GST_VIDEO_FORMAT_UYVP, "GST_VIDEO_FORMAT_UYVP", "uyvp" },
      { GST_VIDEO_FORMAT_A420, "GST_VIDEO_FORMAT_A420", "a420" },
      { GST_VIDEO_FORMAT_RGB8P, "GST_VIDEO_FORMAT_RGB8P", "rgb8p" },
      { GST_VIDEO_FORMAT_YUV9, "GST_VIDEO_FORMAT_YUV9", "yuv9" },
      { GST_VIDEO_FORMAT_YVU9, "GST_VIDEO_FORMAT_YVU9", "yvu9" },
      { GST_VIDEO_FORMAT_IYU1, "GST_VIDEO_FORMAT_IYU1", "iyu1" },
      { GST_VIDEO_FORMAT_ARGB64, "GST_VIDEO_FORMAT_ARGB64", "argb64" },
      { GST_VIDEO_FORMAT_AYUV64, "GST_VIDEO_FORMAT_AYUV64", "ayuv64" },
      { GST_VIDEO_FORMAT_r210, "GST_VIDEO_FORMAT_r210", "r210" },
      { GST_VIDEO_FORMAT_I420_10BE, "GST_VIDEO_FORMAT_I420_10BE", "i420-10be" },
      { GST_VIDEO_FORMAT_I420_10LE, "GST_VIDEO_FORMAT_I420_10LE", "i420-10le" },
      { GST_VIDEO_FORMAT_I422_10BE, "GST_VIDEO_FORMAT_I422_10BE", "i422-10be" },
      { GST_VIDEO_FORMAT_I422_10LE, "GST_VIDEO_FORMAT_I422_10LE", "i422-10le" },
      { GST_VIDEO_FORMAT_Y444_10BE, "GST_VIDEO_FORMAT_Y444_10BE", "y444-10be" },
      { GST_VIDEO_FORMAT_Y444_10LE, "GST_VIDEO_FORMAT_Y444_10LE", "y444-10le" },
      { GST_VIDEO_FORMAT_GBR, "GST_VIDEO_FORMAT_GBR", "gbr" },
      { GST_VIDEO_FORMAT_GBR_10BE, "GST_VIDEO_FORMAT_GBR_10BE", "gbr-10be" },
      { GST_VIDEO_FORMAT_GBR_10LE, "GST_VIDEO_FORMAT_GBR_10LE", "gbr-10le" },
      { GST_VIDEO_FORMAT_NV16, "GST_VIDEO_FORMAT_NV16", "nv16" },
      { GST_VIDEO_FORMAT_NV24, "GST_VIDEO_FORMAT_NV24", "nv24" },
      { 0, NULL, NULL }
    };
    GType g_define_type_id = g_enum_register_static ("GstVideoFormat", values);
    g_once_init_leave (&g_define_type_id__volatile, g_define_type_id);
  }
  return g_define_type_id__volatile;
}
コード例 #19
0
ファイル: thunarx-file-info.c プロジェクト: flipcoder/thunar
GType
thunarx_file_info_get_type (void)
{
  static volatile gsize type__volatile = 0;
  GType                 type;

  if (g_once_init_enter (&type__volatile))
    {
      type = g_type_register_static_simple (G_TYPE_INTERFACE,
                                            I_("ThunarxFileInfo"),
                                            sizeof (ThunarxFileInfoIface),
                                            NULL,
                                            0,
                                            NULL,
                                            0);

      g_type_interface_add_prerequisite (type, G_TYPE_OBJECT);
      
      /**
       * ThunarxFileInfo::changed:
       * @file_info : a #ThunarxFileInfo.
       *
       * Emitted whenever the system notices a change to @file_info.
       *
       * Thunar plugins should use this signal to stay informed about
       * changes to a @file_info for which they currently display
       * information (i.e. in a #ThunarxPropertyPage), and update
       * it's user interface whenever a change is noticed on @file_info.
       **/
      file_info_signals[CHANGED] =
        g_signal_new (I_("changed"),
                      type,
                      G_SIGNAL_RUN_FIRST,
                      G_STRUCT_OFFSET (ThunarxFileInfoIface, changed),
                      NULL, NULL,
                      g_cclosure_marshal_VOID__VOID,
                      G_TYPE_NONE, 0);

      /**
       * ThunarxFileInfo::renamed:
       * @file_info : a #ThunarxFileInfo
       *
       * Emitted when the @file_info is renamed to another
       * name.
       *
       * For example, within Thunar, #ThunarFolder uses this
       * signal to reregister it's VFS directory monitor, after
       * the corresponding file was renamed.
       **/
      file_info_signals[RENAMED] =
        g_signal_new (I_("renamed"),
                      type,
                      G_SIGNAL_RUN_FIRST,
                      G_STRUCT_OFFSET (ThunarxFileInfoIface, renamed),
                      NULL, NULL,
                      g_cclosure_marshal_VOID__VOID,
                      G_TYPE_NONE, 0);

      g_once_init_leave (&type__volatile, type);
    }

  return type__volatile;
}
コード例 #20
0
GType
gst_rtsp_header_field_get_type (void)
{
  static volatile gsize g_define_type_id__volatile = 0;
  if (g_once_init_enter (&g_define_type_id__volatile)) {
    static const GEnumValue values[] = {
      { GST_RTSP_HDR_INVALID, "GST_RTSP_HDR_INVALID", "invalid" },
      { GST_RTSP_HDR_ACCEPT, "GST_RTSP_HDR_ACCEPT", "accept" },
      { GST_RTSP_HDR_ACCEPT_ENCODING, "GST_RTSP_HDR_ACCEPT_ENCODING", "accept-encoding" },
      { GST_RTSP_HDR_ACCEPT_LANGUAGE, "GST_RTSP_HDR_ACCEPT_LANGUAGE", "accept-language" },
      { GST_RTSP_HDR_ALLOW, "GST_RTSP_HDR_ALLOW", "allow" },
      { GST_RTSP_HDR_AUTHORIZATION, "GST_RTSP_HDR_AUTHORIZATION", "authorization" },
      { GST_RTSP_HDR_BANDWIDTH, "GST_RTSP_HDR_BANDWIDTH", "bandwidth" },
      { GST_RTSP_HDR_BLOCKSIZE, "GST_RTSP_HDR_BLOCKSIZE", "blocksize" },
      { GST_RTSP_HDR_CACHE_CONTROL, "GST_RTSP_HDR_CACHE_CONTROL", "cache-control" },
      { GST_RTSP_HDR_CONFERENCE, "GST_RTSP_HDR_CONFERENCE", "conference" },
      { GST_RTSP_HDR_CONNECTION, "GST_RTSP_HDR_CONNECTION", "connection" },
      { GST_RTSP_HDR_CONTENT_BASE, "GST_RTSP_HDR_CONTENT_BASE", "content-base" },
      { GST_RTSP_HDR_CONTENT_ENCODING, "GST_RTSP_HDR_CONTENT_ENCODING", "content-encoding" },
      { GST_RTSP_HDR_CONTENT_LANGUAGE, "GST_RTSP_HDR_CONTENT_LANGUAGE", "content-language" },
      { GST_RTSP_HDR_CONTENT_LENGTH, "GST_RTSP_HDR_CONTENT_LENGTH", "content-length" },
      { GST_RTSP_HDR_CONTENT_LOCATION, "GST_RTSP_HDR_CONTENT_LOCATION", "content-location" },
      { GST_RTSP_HDR_CONTENT_TYPE, "GST_RTSP_HDR_CONTENT_TYPE", "content-type" },
      { GST_RTSP_HDR_CSEQ, "GST_RTSP_HDR_CSEQ", "cseq" },
      { GST_RTSP_HDR_DATE, "GST_RTSP_HDR_DATE", "date" },
      { GST_RTSP_HDR_EXPIRES, "GST_RTSP_HDR_EXPIRES", "expires" },
      { GST_RTSP_HDR_FROM, "GST_RTSP_HDR_FROM", "from" },
      { GST_RTSP_HDR_IF_MODIFIED_SINCE, "GST_RTSP_HDR_IF_MODIFIED_SINCE", "if-modified-since" },
      { GST_RTSP_HDR_LAST_MODIFIED, "GST_RTSP_HDR_LAST_MODIFIED", "last-modified" },
      { GST_RTSP_HDR_PROXY_AUTHENTICATE, "GST_RTSP_HDR_PROXY_AUTHENTICATE", "proxy-authenticate" },
      { GST_RTSP_HDR_PROXY_REQUIRE, "GST_RTSP_HDR_PROXY_REQUIRE", "proxy-require" },
      { GST_RTSP_HDR_PUBLIC, "GST_RTSP_HDR_PUBLIC", "public" },
      { GST_RTSP_HDR_RANGE, "GST_RTSP_HDR_RANGE", "range" },
      { GST_RTSP_HDR_REFERER, "GST_RTSP_HDR_REFERER", "referer" },
      { GST_RTSP_HDR_REQUIRE, "GST_RTSP_HDR_REQUIRE", "require" },
      { GST_RTSP_HDR_RETRY_AFTER, "GST_RTSP_HDR_RETRY_AFTER", "retry-after" },
      { GST_RTSP_HDR_RTP_INFO, "GST_RTSP_HDR_RTP_INFO", "rtp-info" },
      { GST_RTSP_HDR_SCALE, "GST_RTSP_HDR_SCALE", "scale" },
      { GST_RTSP_HDR_SESSION, "GST_RTSP_HDR_SESSION", "session" },
      { GST_RTSP_HDR_SERVER, "GST_RTSP_HDR_SERVER", "server" },
      { GST_RTSP_HDR_SPEED, "GST_RTSP_HDR_SPEED", "speed" },
      { GST_RTSP_HDR_TRANSPORT, "GST_RTSP_HDR_TRANSPORT", "transport" },
      { GST_RTSP_HDR_UNSUPPORTED, "GST_RTSP_HDR_UNSUPPORTED", "unsupported" },
      { GST_RTSP_HDR_USER_AGENT, "GST_RTSP_HDR_USER_AGENT", "user-agent" },
      { GST_RTSP_HDR_VIA, "GST_RTSP_HDR_VIA", "via" },
      { GST_RTSP_HDR_WWW_AUTHENTICATE, "GST_RTSP_HDR_WWW_AUTHENTICATE", "www-authenticate" },
      { GST_RTSP_HDR_CLIENT_CHALLENGE, "GST_RTSP_HDR_CLIENT_CHALLENGE", "client-challenge" },
      { GST_RTSP_HDR_REAL_CHALLENGE1, "GST_RTSP_HDR_REAL_CHALLENGE1", "real-challenge1" },
      { GST_RTSP_HDR_REAL_CHALLENGE2, "GST_RTSP_HDR_REAL_CHALLENGE2", "real-challenge2" },
      { GST_RTSP_HDR_REAL_CHALLENGE3, "GST_RTSP_HDR_REAL_CHALLENGE3", "real-challenge3" },
      { GST_RTSP_HDR_SUBSCRIBE, "GST_RTSP_HDR_SUBSCRIBE", "subscribe" },
      { GST_RTSP_HDR_ALERT, "GST_RTSP_HDR_ALERT", "alert" },
      { GST_RTSP_HDR_CLIENT_ID, "GST_RTSP_HDR_CLIENT_ID", "client-id" },
      { GST_RTSP_HDR_COMPANY_ID, "GST_RTSP_HDR_COMPANY_ID", "company-id" },
      { GST_RTSP_HDR_GUID, "GST_RTSP_HDR_GUID", "guid" },
      { GST_RTSP_HDR_REGION_DATA, "GST_RTSP_HDR_REGION_DATA", "region-data" },
      { GST_RTSP_HDR_MAX_ASM_WIDTH, "GST_RTSP_HDR_MAX_ASM_WIDTH", "max-asm-width" },
      { GST_RTSP_HDR_LANGUAGE, "GST_RTSP_HDR_LANGUAGE", "language" },
      { GST_RTSP_HDR_PLAYER_START_TIME, "GST_RTSP_HDR_PLAYER_START_TIME", "player-start-time" },
      { GST_RTSP_HDR_LOCATION, "GST_RTSP_HDR_LOCATION", "location" },
      { GST_RTSP_HDR_ETAG, "GST_RTSP_HDR_ETAG", "etag" },
      { GST_RTSP_HDR_IF_MATCH, "GST_RTSP_HDR_IF_MATCH", "if-match" },
      { GST_RTSP_HDR_ACCEPT_CHARSET, "GST_RTSP_HDR_ACCEPT_CHARSET", "accept-charset" },
      { GST_RTSP_HDR_SUPPORTED, "GST_RTSP_HDR_SUPPORTED", "supported" },
      { GST_RTSP_HDR_VARY, "GST_RTSP_HDR_VARY", "vary" },
      { GST_RTSP_HDR_X_ACCELERATE_STREAMING, "GST_RTSP_HDR_X_ACCELERATE_STREAMING", "x-accelerate-streaming" },
      { GST_RTSP_HDR_X_ACCEPT_AUTHENT, "GST_RTSP_HDR_X_ACCEPT_AUTHENT", "x-accept-authent" },
      { GST_RTSP_HDR_X_ACCEPT_PROXY_AUTHENT, "GST_RTSP_HDR_X_ACCEPT_PROXY_AUTHENT", "x-accept-proxy-authent" },
      { GST_RTSP_HDR_X_BROADCAST_ID, "GST_RTSP_HDR_X_BROADCAST_ID", "x-broadcast-id" },
      { GST_RTSP_HDR_X_BURST_STREAMING, "GST_RTSP_HDR_X_BURST_STREAMING", "x-burst-streaming" },
      { GST_RTSP_HDR_X_NOTICE, "GST_RTSP_HDR_X_NOTICE", "x-notice" },
      { GST_RTSP_HDR_X_PLAYER_LAG_TIME, "GST_RTSP_HDR_X_PLAYER_LAG_TIME", "x-player-lag-time" },
      { GST_RTSP_HDR_X_PLAYLIST, "GST_RTSP_HDR_X_PLAYLIST", "x-playlist" },
      { GST_RTSP_HDR_X_PLAYLIST_CHANGE_NOTICE, "GST_RTSP_HDR_X_PLAYLIST_CHANGE_NOTICE", "x-playlist-change-notice" },
      { GST_RTSP_HDR_X_PLAYLIST_GEN_ID, "GST_RTSP_HDR_X_PLAYLIST_GEN_ID", "x-playlist-gen-id" },
      { GST_RTSP_HDR_X_PLAYLIST_SEEK_ID, "GST_RTSP_HDR_X_PLAYLIST_SEEK_ID", "x-playlist-seek-id" },
      { GST_RTSP_HDR_X_PROXY_CLIENT_AGENT, "GST_RTSP_HDR_X_PROXY_CLIENT_AGENT", "x-proxy-client-agent" },
      { GST_RTSP_HDR_X_PROXY_CLIENT_VERB, "GST_RTSP_HDR_X_PROXY_CLIENT_VERB", "x-proxy-client-verb" },
      { GST_RTSP_HDR_X_RECEDING_PLAYLISTCHANGE, "GST_RTSP_HDR_X_RECEDING_PLAYLISTCHANGE", "x-receding-playlistchange" },
      { GST_RTSP_HDR_X_RTP_INFO, "GST_RTSP_HDR_X_RTP_INFO", "x-rtp-info" },
      { GST_RTSP_HDR_X_STARTUPPROFILE, "GST_RTSP_HDR_X_STARTUPPROFILE", "x-startupprofile" },
      { GST_RTSP_HDR_TIMESTAMP, "GST_RTSP_HDR_TIMESTAMP", "timestamp" },
      { GST_RTSP_HDR_AUTHENTICATION_INFO, "GST_RTSP_HDR_AUTHENTICATION_INFO", "authentication-info" },
      { GST_RTSP_HDR_HOST, "GST_RTSP_HDR_HOST", "host" },
      { GST_RTSP_HDR_PRAGMA, "GST_RTSP_HDR_PRAGMA", "pragma" },
      { GST_RTSP_HDR_X_SERVER_IP_ADDRESS, "GST_RTSP_HDR_X_SERVER_IP_ADDRESS", "x-server-ip-address" },
      { GST_RTSP_HDR_X_SESSIONCOOKIE, "GST_RTSP_HDR_X_SESSIONCOOKIE", "x-sessioncookie" },
      { GST_RTSP_HDR_LAST, "GST_RTSP_HDR_LAST", "last" },
      { 0, NULL, NULL }
    };
    GType g_define_type_id = g_enum_register_static ("GstRTSPHeaderField", values);
    g_once_init_leave (&g_define_type_id__volatile, g_define_type_id);
  }
  return g_define_type_id__volatile;
}
コード例 #21
0
/* enumerations from "pango-script.h" */
GType
pango_script_get_type (void)
{
    static volatile gsize g_define_type_id__volatile = 0;

    if (g_once_init_enter (&g_define_type_id__volatile))
    {
        static const GEnumValue values[] = {
            { PANGO_SCRIPT_INVALID_CODE, "PANGO_SCRIPT_INVALID_CODE", "invalid-code" },
            { PANGO_SCRIPT_COMMON, "PANGO_SCRIPT_COMMON", "common" },
            { PANGO_SCRIPT_INHERITED, "PANGO_SCRIPT_INHERITED", "inherited" },
            { PANGO_SCRIPT_ARABIC, "PANGO_SCRIPT_ARABIC", "arabic" },
            { PANGO_SCRIPT_ARMENIAN, "PANGO_SCRIPT_ARMENIAN", "armenian" },
            { PANGO_SCRIPT_BENGALI, "PANGO_SCRIPT_BENGALI", "bengali" },
            { PANGO_SCRIPT_BOPOMOFO, "PANGO_SCRIPT_BOPOMOFO", "bopomofo" },
            { PANGO_SCRIPT_CHEROKEE, "PANGO_SCRIPT_CHEROKEE", "cherokee" },
            { PANGO_SCRIPT_COPTIC, "PANGO_SCRIPT_COPTIC", "coptic" },
            { PANGO_SCRIPT_CYRILLIC, "PANGO_SCRIPT_CYRILLIC", "cyrillic" },
            { PANGO_SCRIPT_DESERET, "PANGO_SCRIPT_DESERET", "deseret" },
            { PANGO_SCRIPT_DEVANAGARI, "PANGO_SCRIPT_DEVANAGARI", "devanagari" },
            { PANGO_SCRIPT_ETHIOPIC, "PANGO_SCRIPT_ETHIOPIC", "ethiopic" },
            { PANGO_SCRIPT_GEORGIAN, "PANGO_SCRIPT_GEORGIAN", "georgian" },
            { PANGO_SCRIPT_GOTHIC, "PANGO_SCRIPT_GOTHIC", "gothic" },
            { PANGO_SCRIPT_GREEK, "PANGO_SCRIPT_GREEK", "greek" },
            { PANGO_SCRIPT_GUJARATI, "PANGO_SCRIPT_GUJARATI", "gujarati" },
            { PANGO_SCRIPT_GURMUKHI, "PANGO_SCRIPT_GURMUKHI", "gurmukhi" },
            { PANGO_SCRIPT_HAN, "PANGO_SCRIPT_HAN", "han" },
            { PANGO_SCRIPT_HANGUL, "PANGO_SCRIPT_HANGUL", "hangul" },
            { PANGO_SCRIPT_HEBREW, "PANGO_SCRIPT_HEBREW", "hebrew" },
            { PANGO_SCRIPT_HIRAGANA, "PANGO_SCRIPT_HIRAGANA", "hiragana" },
            { PANGO_SCRIPT_KANNADA, "PANGO_SCRIPT_KANNADA", "kannada" },
            { PANGO_SCRIPT_KATAKANA, "PANGO_SCRIPT_KATAKANA", "katakana" },
            { PANGO_SCRIPT_KHMER, "PANGO_SCRIPT_KHMER", "khmer" },
            { PANGO_SCRIPT_LAO, "PANGO_SCRIPT_LAO", "lao" },
            { PANGO_SCRIPT_LATIN, "PANGO_SCRIPT_LATIN", "latin" },
            { PANGO_SCRIPT_MALAYALAM, "PANGO_SCRIPT_MALAYALAM", "malayalam" },
            { PANGO_SCRIPT_MONGOLIAN, "PANGO_SCRIPT_MONGOLIAN", "mongolian" },
            { PANGO_SCRIPT_MYANMAR, "PANGO_SCRIPT_MYANMAR", "myanmar" },
            { PANGO_SCRIPT_OGHAM, "PANGO_SCRIPT_OGHAM", "ogham" },
            { PANGO_SCRIPT_OLD_ITALIC, "PANGO_SCRIPT_OLD_ITALIC", "old-italic" },
            { PANGO_SCRIPT_ORIYA, "PANGO_SCRIPT_ORIYA", "oriya" },
            { PANGO_SCRIPT_RUNIC, "PANGO_SCRIPT_RUNIC", "runic" },
            { PANGO_SCRIPT_SINHALA, "PANGO_SCRIPT_SINHALA", "sinhala" },
            { PANGO_SCRIPT_SYRIAC, "PANGO_SCRIPT_SYRIAC", "syriac" },
            { PANGO_SCRIPT_TAMIL, "PANGO_SCRIPT_TAMIL", "tamil" },
            { PANGO_SCRIPT_TELUGU, "PANGO_SCRIPT_TELUGU", "telugu" },
            { PANGO_SCRIPT_THAANA, "PANGO_SCRIPT_THAANA", "thaana" },
            { PANGO_SCRIPT_THAI, "PANGO_SCRIPT_THAI", "thai" },
            { PANGO_SCRIPT_TIBETAN, "PANGO_SCRIPT_TIBETAN", "tibetan" },
            { PANGO_SCRIPT_CANADIAN_ABORIGINAL, "PANGO_SCRIPT_CANADIAN_ABORIGINAL", "canadian-aboriginal" },
            { PANGO_SCRIPT_YI, "PANGO_SCRIPT_YI", "yi" },
            { PANGO_SCRIPT_TAGALOG, "PANGO_SCRIPT_TAGALOG", "tagalog" },
            { PANGO_SCRIPT_HANUNOO, "PANGO_SCRIPT_HANUNOO", "hanunoo" },
            { PANGO_SCRIPT_BUHID, "PANGO_SCRIPT_BUHID", "buhid" },
            { PANGO_SCRIPT_TAGBANWA, "PANGO_SCRIPT_TAGBANWA", "tagbanwa" },
            { PANGO_SCRIPT_BRAILLE, "PANGO_SCRIPT_BRAILLE", "braille" },
            { PANGO_SCRIPT_CYPRIOT, "PANGO_SCRIPT_CYPRIOT", "cypriot" },
            { PANGO_SCRIPT_LIMBU, "PANGO_SCRIPT_LIMBU", "limbu" },
            { PANGO_SCRIPT_OSMANYA, "PANGO_SCRIPT_OSMANYA", "osmanya" },
            { PANGO_SCRIPT_SHAVIAN, "PANGO_SCRIPT_SHAVIAN", "shavian" },
            { PANGO_SCRIPT_LINEAR_B, "PANGO_SCRIPT_LINEAR_B", "linear-b" },
            { PANGO_SCRIPT_TAI_LE, "PANGO_SCRIPT_TAI_LE", "tai-le" },
            { PANGO_SCRIPT_UGARITIC, "PANGO_SCRIPT_UGARITIC", "ugaritic" },
            { PANGO_SCRIPT_NEW_TAI_LUE, "PANGO_SCRIPT_NEW_TAI_LUE", "new-tai-lue" },
            { PANGO_SCRIPT_BUGINESE, "PANGO_SCRIPT_BUGINESE", "buginese" },
            { PANGO_SCRIPT_GLAGOLITIC, "PANGO_SCRIPT_GLAGOLITIC", "glagolitic" },
            { PANGO_SCRIPT_TIFINAGH, "PANGO_SCRIPT_TIFINAGH", "tifinagh" },
            { PANGO_SCRIPT_SYLOTI_NAGRI, "PANGO_SCRIPT_SYLOTI_NAGRI", "syloti-nagri" },
            { PANGO_SCRIPT_OLD_PERSIAN, "PANGO_SCRIPT_OLD_PERSIAN", "old-persian" },
            { PANGO_SCRIPT_KHAROSHTHI, "PANGO_SCRIPT_KHAROSHTHI", "kharoshthi" },
            { PANGO_SCRIPT_UNKNOWN, "PANGO_SCRIPT_UNKNOWN", "unknown" },
            { PANGO_SCRIPT_BALINESE, "PANGO_SCRIPT_BALINESE", "balinese" },
            { PANGO_SCRIPT_CUNEIFORM, "PANGO_SCRIPT_CUNEIFORM", "cuneiform" },
            { PANGO_SCRIPT_PHOENICIAN, "PANGO_SCRIPT_PHOENICIAN", "phoenician" },
            { PANGO_SCRIPT_PHAGS_PA, "PANGO_SCRIPT_PHAGS_PA", "phags-pa" },
            { PANGO_SCRIPT_NKO, "PANGO_SCRIPT_NKO", "nko" },
            { PANGO_SCRIPT_KAYAH_LI, "PANGO_SCRIPT_KAYAH_LI", "kayah-li" },
            { PANGO_SCRIPT_LEPCHA, "PANGO_SCRIPT_LEPCHA", "lepcha" },
            { PANGO_SCRIPT_REJANG, "PANGO_SCRIPT_REJANG", "rejang" },
            { PANGO_SCRIPT_SUNDANESE, "PANGO_SCRIPT_SUNDANESE", "sundanese" },
            { PANGO_SCRIPT_SAURASHTRA, "PANGO_SCRIPT_SAURASHTRA", "saurashtra" },
            { PANGO_SCRIPT_CHAM, "PANGO_SCRIPT_CHAM", "cham" },
            { PANGO_SCRIPT_OL_CHIKI, "PANGO_SCRIPT_OL_CHIKI", "ol-chiki" },
            { PANGO_SCRIPT_VAI, "PANGO_SCRIPT_VAI", "vai" },
            { PANGO_SCRIPT_CARIAN, "PANGO_SCRIPT_CARIAN", "carian" },
            { PANGO_SCRIPT_LYCIAN, "PANGO_SCRIPT_LYCIAN", "lycian" },
            { PANGO_SCRIPT_LYDIAN, "PANGO_SCRIPT_LYDIAN", "lydian" },
            { PANGO_SCRIPT_BATAK, "PANGO_SCRIPT_BATAK", "batak" },
            { PANGO_SCRIPT_BRAHMI, "PANGO_SCRIPT_BRAHMI", "brahmi" },
            { PANGO_SCRIPT_MANDAIC, "PANGO_SCRIPT_MANDAIC", "mandaic" },
            { PANGO_SCRIPT_CHAKMA, "PANGO_SCRIPT_CHAKMA", "chakma" },
            { PANGO_SCRIPT_MEROITIC_CURSIVE, "PANGO_SCRIPT_MEROITIC_CURSIVE", "meroitic-cursive" },
            { PANGO_SCRIPT_MEROITIC_HIEROGLYPHS, "PANGO_SCRIPT_MEROITIC_HIEROGLYPHS", "meroitic-hieroglyphs" },
            { PANGO_SCRIPT_MIAO, "PANGO_SCRIPT_MIAO", "miao" },
            { PANGO_SCRIPT_SHARADA, "PANGO_SCRIPT_SHARADA", "sharada" },
            { PANGO_SCRIPT_SORA_SOMPENG, "PANGO_SCRIPT_SORA_SOMPENG", "sora-sompeng" },
            { PANGO_SCRIPT_TAKRI, "PANGO_SCRIPT_TAKRI", "takri" },
            { 0, NULL, NULL }
        };
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("PangoScript"), values);
        g_once_init_leave (&g_define_type_id__volatile, g_define_type_id);
    }

    return g_define_type_id__volatile;
}
コード例 #22
0
GType
poppler_structure_element_kind_get_type (void)
{
  static volatile gsize g_define_type_id__volatile = 0;
 
  if (g_once_init_enter (&g_define_type_id__volatile)) {
    static const GEnumValue values[] = {
      { POPPLER_STRUCTURE_ELEMENT_CONTENT, "POPPLER_STRUCTURE_ELEMENT_CONTENT", "content" },
      { POPPLER_STRUCTURE_ELEMENT_OBJECT_REFERENCE, "POPPLER_STRUCTURE_ELEMENT_OBJECT_REFERENCE", "object-reference" },
      { POPPLER_STRUCTURE_ELEMENT_DOCUMENT, "POPPLER_STRUCTURE_ELEMENT_DOCUMENT", "document" },
      { POPPLER_STRUCTURE_ELEMENT_PART, "POPPLER_STRUCTURE_ELEMENT_PART", "part" },
      { POPPLER_STRUCTURE_ELEMENT_ARTICLE, "POPPLER_STRUCTURE_ELEMENT_ARTICLE", "article" },
      { POPPLER_STRUCTURE_ELEMENT_SECTION, "POPPLER_STRUCTURE_ELEMENT_SECTION", "section" },
      { POPPLER_STRUCTURE_ELEMENT_DIV, "POPPLER_STRUCTURE_ELEMENT_DIV", "div" },
      { POPPLER_STRUCTURE_ELEMENT_SPAN, "POPPLER_STRUCTURE_ELEMENT_SPAN", "span" },
      { POPPLER_STRUCTURE_ELEMENT_QUOTE, "POPPLER_STRUCTURE_ELEMENT_QUOTE", "quote" },
      { POPPLER_STRUCTURE_ELEMENT_NOTE, "POPPLER_STRUCTURE_ELEMENT_NOTE", "note" },
      { POPPLER_STRUCTURE_ELEMENT_REFERENCE, "POPPLER_STRUCTURE_ELEMENT_REFERENCE", "reference" },
      { POPPLER_STRUCTURE_ELEMENT_BIBENTRY, "POPPLER_STRUCTURE_ELEMENT_BIBENTRY", "bibentry" },
      { POPPLER_STRUCTURE_ELEMENT_CODE, "POPPLER_STRUCTURE_ELEMENT_CODE", "code" },
      { POPPLER_STRUCTURE_ELEMENT_LINK, "POPPLER_STRUCTURE_ELEMENT_LINK", "link" },
      { POPPLER_STRUCTURE_ELEMENT_ANNOT, "POPPLER_STRUCTURE_ELEMENT_ANNOT", "annot" },
      { POPPLER_STRUCTURE_ELEMENT_BLOCKQUOTE, "POPPLER_STRUCTURE_ELEMENT_BLOCKQUOTE", "blockquote" },
      { POPPLER_STRUCTURE_ELEMENT_CAPTION, "POPPLER_STRUCTURE_ELEMENT_CAPTION", "caption" },
      { POPPLER_STRUCTURE_ELEMENT_NONSTRUCT, "POPPLER_STRUCTURE_ELEMENT_NONSTRUCT", "nonstruct" },
      { POPPLER_STRUCTURE_ELEMENT_TOC, "POPPLER_STRUCTURE_ELEMENT_TOC", "toc" },
      { POPPLER_STRUCTURE_ELEMENT_TOC_ITEM, "POPPLER_STRUCTURE_ELEMENT_TOC_ITEM", "toc-item" },
      { POPPLER_STRUCTURE_ELEMENT_INDEX, "POPPLER_STRUCTURE_ELEMENT_INDEX", "index" },
      { POPPLER_STRUCTURE_ELEMENT_PRIVATE, "POPPLER_STRUCTURE_ELEMENT_PRIVATE", "private" },
      { POPPLER_STRUCTURE_ELEMENT_PARAGRAPH, "POPPLER_STRUCTURE_ELEMENT_PARAGRAPH", "paragraph" },
      { POPPLER_STRUCTURE_ELEMENT_HEADING, "POPPLER_STRUCTURE_ELEMENT_HEADING", "heading" },
      { POPPLER_STRUCTURE_ELEMENT_HEADING_1, "POPPLER_STRUCTURE_ELEMENT_HEADING_1", "heading-1" },
      { POPPLER_STRUCTURE_ELEMENT_HEADING_2, "POPPLER_STRUCTURE_ELEMENT_HEADING_2", "heading-2" },
      { POPPLER_STRUCTURE_ELEMENT_HEADING_3, "POPPLER_STRUCTURE_ELEMENT_HEADING_3", "heading-3" },
      { POPPLER_STRUCTURE_ELEMENT_HEADING_4, "POPPLER_STRUCTURE_ELEMENT_HEADING_4", "heading-4" },
      { POPPLER_STRUCTURE_ELEMENT_HEADING_5, "POPPLER_STRUCTURE_ELEMENT_HEADING_5", "heading-5" },
      { POPPLER_STRUCTURE_ELEMENT_HEADING_6, "POPPLER_STRUCTURE_ELEMENT_HEADING_6", "heading-6" },
      { POPPLER_STRUCTURE_ELEMENT_LIST, "POPPLER_STRUCTURE_ELEMENT_LIST", "list" },
      { POPPLER_STRUCTURE_ELEMENT_LIST_ITEM, "POPPLER_STRUCTURE_ELEMENT_LIST_ITEM", "list-item" },
      { POPPLER_STRUCTURE_ELEMENT_LIST_LABEL, "POPPLER_STRUCTURE_ELEMENT_LIST_LABEL", "list-label" },
      { POPPLER_STRUCTURE_ELEMENT_LIST_BODY, "POPPLER_STRUCTURE_ELEMENT_LIST_BODY", "list-body" },
      { POPPLER_STRUCTURE_ELEMENT_TABLE, "POPPLER_STRUCTURE_ELEMENT_TABLE", "table" },
      { POPPLER_STRUCTURE_ELEMENT_TABLE_ROW, "POPPLER_STRUCTURE_ELEMENT_TABLE_ROW", "table-row" },
      { POPPLER_STRUCTURE_ELEMENT_TABLE_HEADING, "POPPLER_STRUCTURE_ELEMENT_TABLE_HEADING", "table-heading" },
      { POPPLER_STRUCTURE_ELEMENT_TABLE_DATA, "POPPLER_STRUCTURE_ELEMENT_TABLE_DATA", "table-data" },
      { POPPLER_STRUCTURE_ELEMENT_TABLE_HEADER, "POPPLER_STRUCTURE_ELEMENT_TABLE_HEADER", "table-header" },
      { POPPLER_STRUCTURE_ELEMENT_TABLE_FOOTER, "POPPLER_STRUCTURE_ELEMENT_TABLE_FOOTER", "table-footer" },
      { POPPLER_STRUCTURE_ELEMENT_TABLE_BODY, "POPPLER_STRUCTURE_ELEMENT_TABLE_BODY", "table-body" },
      { POPPLER_STRUCTURE_ELEMENT_RUBY, "POPPLER_STRUCTURE_ELEMENT_RUBY", "ruby" },
      { POPPLER_STRUCTURE_ELEMENT_RUBY_BASE_TEXT, "POPPLER_STRUCTURE_ELEMENT_RUBY_BASE_TEXT", "ruby-base-text" },
      { POPPLER_STRUCTURE_ELEMENT_RUBY_ANNOT_TEXT, "POPPLER_STRUCTURE_ELEMENT_RUBY_ANNOT_TEXT", "ruby-annot-text" },
      { POPPLER_STRUCTURE_ELEMENT_RUBY_PUNCTUATION, "POPPLER_STRUCTURE_ELEMENT_RUBY_PUNCTUATION", "ruby-punctuation" },
      { POPPLER_STRUCTURE_ELEMENT_WARICHU, "POPPLER_STRUCTURE_ELEMENT_WARICHU", "warichu" },
      { POPPLER_STRUCTURE_ELEMENT_WARICHU_TEXT, "POPPLER_STRUCTURE_ELEMENT_WARICHU_TEXT", "warichu-text" },
      { POPPLER_STRUCTURE_ELEMENT_WARICHU_PUNCTUATION, "POPPLER_STRUCTURE_ELEMENT_WARICHU_PUNCTUATION", "warichu-punctuation" },
      { POPPLER_STRUCTURE_ELEMENT_FIGURE, "POPPLER_STRUCTURE_ELEMENT_FIGURE", "figure" },
      { POPPLER_STRUCTURE_ELEMENT_FORMULA, "POPPLER_STRUCTURE_ELEMENT_FORMULA", "formula" },
      { POPPLER_STRUCTURE_ELEMENT_FORM, "POPPLER_STRUCTURE_ELEMENT_FORM", "form" },
      { 0, NULL, NULL }
    };
    GType g_define_type_id = 
       g_enum_register_static (g_intern_static_string ("PopplerStructureElementKind"), values);
      
    g_once_init_leave (&g_define_type_id__volatile, g_define_type_id);
  }
    
  return g_define_type_id__volatile;
}
コード例 #23
0
/* enumerations from "audio-channels.h" */
GType
gst_audio_channel_position_get_type (void)
{
  static volatile gsize g_define_type_id__volatile = 0;
  if (g_once_init_enter (&g_define_type_id__volatile)) {
    static const GEnumValue values[] = {
      {GST_AUDIO_CHANNEL_POSITION_NONE, "GST_AUDIO_CHANNEL_POSITION_NONE",
          "none"},
      {GST_AUDIO_CHANNEL_POSITION_MONO, "GST_AUDIO_CHANNEL_POSITION_MONO",
          "mono"},
      {GST_AUDIO_CHANNEL_POSITION_INVALID, "GST_AUDIO_CHANNEL_POSITION_INVALID",
          "invalid"},
      {GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT,
          "GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT", "front-left"},
      {GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT,
          "GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT", "front-right"},
      {GST_AUDIO_CHANNEL_POSITION_FRONT_CENTER,
          "GST_AUDIO_CHANNEL_POSITION_FRONT_CENTER", "front-center"},
      {GST_AUDIO_CHANNEL_POSITION_LFE1, "GST_AUDIO_CHANNEL_POSITION_LFE1",
          "lfe1"},
      {GST_AUDIO_CHANNEL_POSITION_REAR_LEFT,
          "GST_AUDIO_CHANNEL_POSITION_REAR_LEFT", "rear-left"},
      {GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT,
          "GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT", "rear-right"},
      {GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT_OF_CENTER,
            "GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT_OF_CENTER",
          "front-left-of-center"},
      {GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT_OF_CENTER,
            "GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT_OF_CENTER",
          "front-right-of-center"},
      {GST_AUDIO_CHANNEL_POSITION_REAR_CENTER,
          "GST_AUDIO_CHANNEL_POSITION_REAR_CENTER", "rear-center"},
      {GST_AUDIO_CHANNEL_POSITION_LFE2, "GST_AUDIO_CHANNEL_POSITION_LFE2",
          "lfe2"},
      {GST_AUDIO_CHANNEL_POSITION_SIDE_LEFT,
          "GST_AUDIO_CHANNEL_POSITION_SIDE_LEFT", "side-left"},
      {GST_AUDIO_CHANNEL_POSITION_SIDE_RIGHT,
          "GST_AUDIO_CHANNEL_POSITION_SIDE_RIGHT", "side-right"},
      {GST_AUDIO_CHANNEL_POSITION_TOP_FRONT_LEFT,
          "GST_AUDIO_CHANNEL_POSITION_TOP_FRONT_LEFT", "top-front-left"},
      {GST_AUDIO_CHANNEL_POSITION_TOP_FRONT_RIGHT,
          "GST_AUDIO_CHANNEL_POSITION_TOP_FRONT_RIGHT", "top-front-right"},
      {GST_AUDIO_CHANNEL_POSITION_TOP_FRONT_CENTER,
          "GST_AUDIO_CHANNEL_POSITION_TOP_FRONT_CENTER", "top-front-center"},
      {GST_AUDIO_CHANNEL_POSITION_TOP_CENTER,
          "GST_AUDIO_CHANNEL_POSITION_TOP_CENTER", "top-center"},
      {GST_AUDIO_CHANNEL_POSITION_TOP_REAR_LEFT,
          "GST_AUDIO_CHANNEL_POSITION_TOP_REAR_LEFT", "top-rear-left"},
      {GST_AUDIO_CHANNEL_POSITION_TOP_REAR_RIGHT,
          "GST_AUDIO_CHANNEL_POSITION_TOP_REAR_RIGHT", "top-rear-right"},
      {GST_AUDIO_CHANNEL_POSITION_TOP_SIDE_LEFT,
          "GST_AUDIO_CHANNEL_POSITION_TOP_SIDE_LEFT", "top-side-left"},
      {GST_AUDIO_CHANNEL_POSITION_TOP_SIDE_RIGHT,
          "GST_AUDIO_CHANNEL_POSITION_TOP_SIDE_RIGHT", "top-side-right"},
      {GST_AUDIO_CHANNEL_POSITION_TOP_REAR_CENTER,
          "GST_AUDIO_CHANNEL_POSITION_TOP_REAR_CENTER", "top-rear-center"},
      {GST_AUDIO_CHANNEL_POSITION_BOTTOM_FRONT_CENTER,
            "GST_AUDIO_CHANNEL_POSITION_BOTTOM_FRONT_CENTER",
          "bottom-front-center"},
      {GST_AUDIO_CHANNEL_POSITION_BOTTOM_FRONT_LEFT,
            "GST_AUDIO_CHANNEL_POSITION_BOTTOM_FRONT_LEFT",
          "bottom-front-left"},
      {GST_AUDIO_CHANNEL_POSITION_BOTTOM_FRONT_RIGHT,
            "GST_AUDIO_CHANNEL_POSITION_BOTTOM_FRONT_RIGHT",
          "bottom-front-right"},
      {GST_AUDIO_CHANNEL_POSITION_WIDE_LEFT,
          "GST_AUDIO_CHANNEL_POSITION_WIDE_LEFT", "wide-left"},
      {GST_AUDIO_CHANNEL_POSITION_WIDE_RIGHT,
          "GST_AUDIO_CHANNEL_POSITION_WIDE_RIGHT", "wide-right"},
      {GST_AUDIO_CHANNEL_POSITION_SURROUND_LEFT,
          "GST_AUDIO_CHANNEL_POSITION_SURROUND_LEFT", "surround-left"},
      {GST_AUDIO_CHANNEL_POSITION_SURROUND_RIGHT,
          "GST_AUDIO_CHANNEL_POSITION_SURROUND_RIGHT", "surround-right"},
      {0, NULL, NULL}
    };
    GType g_define_type_id =
        g_enum_register_static ("GstAudioChannelPosition", values);
    g_once_init_leave (&g_define_type_id__volatile, g_define_type_id);
  }
  return g_define_type_id__volatile;
}
コード例 #24
0
GType
gucharmap_chartable_accessible_get_type (void)
{
  static volatile gsize type__volatile = 0;

  if (g_once_init_enter (&type__volatile))
    {
      GTypeInfo typeinfo =
      {
        0 /* filled in by the code below */,
        (GBaseInitFunc) NULL, /* base init */
        (GBaseFinalizeFunc) NULL, /* base finalize */
        (GClassInitFunc) gucharmap_chartable_accessible_class_init, /* class init */
        (GClassFinalizeFunc) NULL, /* class finalize */
        NULL, /* class data */
        0 /* filled in by the code below */,
        0, /* nb preallocs */
        (GInstanceInitFunc) gucharmap_chartable_accessible_init, /* instance init */
        NULL /* value table */
      };
      const GInterfaceInfo atk_table_info =
      {
          (GInterfaceInitFunc) gucharmap_chartable_accessible_table_interface_init,
          (GInterfaceFinalizeFunc) NULL,
          NULL
      };
      const GInterfaceInfo atk_component_info =
      {
          (GInterfaceInitFunc) gucharmap_chartable_accessible_component_interface_init,
          (GInterfaceFinalizeFunc) NULL,
          NULL
      };
      AtkObjectFactory *factory;
      GType derived_type;
      GTypeQuery query;
      GType derived_atk_type;
      GType type;

      /* Figure out the size of the class and instance we are deriving from */
      derived_type = g_type_parent (GUCHARMAP_TYPE_CHARTABLE);
      factory = atk_registry_get_factory (atk_get_default_registry (), 
                                          derived_type);
      derived_atk_type = atk_object_factory_get_accessible_type (factory);
      g_type_query (derived_atk_type, &query);
      typeinfo.class_size = query.class_size;
      typeinfo.instance_size = query.instance_size;

      type = g_type_register_static (derived_atk_type,
                                     "GucharmapChartableAccessible",
                                     &typeinfo, 0);

      g_type_add_interface_static (type, ATK_TYPE_TABLE,
                                   &atk_table_info);
      g_type_add_interface_static (type, ATK_TYPE_COMPONENT,
                                   &atk_component_info);

      g_once_init_leave (&type__volatile, type);
    }

  return type__volatile;
}
コード例 #25
0
ファイル: misc.c プロジェクト: svn2github/GtkAda
int
ada_initialize_class_record
  (GType         ancestor,
   gint          nsignals,
   char*         signals[],
   GType         parameters[],
   gint          max_parameters,
   GType         returns[],
   gint          max_returns,
   AdaGObjectClass klass,
   gchar*        type_name)
{
   // Make this function thread-safe and ensure we only initialize the class
   // once
   if (g_once_init_enter (&klass->type)) {
       /* Note: The memory allocated in this function is never freed. No need
          to worry, since this is only allocated once per user's widget type,
          and might be used until the end of the application */

       GTypeQuery query;
       int j;

       /* We need to know the ancestor's class/instance sizes */
       g_type_query (ancestor, &query);

       /*************************
        * This code is the equivalent of [email protected]@_get_type in C. In Ada, the
        * type will be accessible only once at least one instance of it has
        * been created (whereas in C the GType is created at elaboration time).
        *************************/

       GTypeInfo info;
       info.class_size = query.class_size
              + nsignals * sizeof (void*);
              //+ sizeof (AdaGObjectClass);
       info.base_init = NULL;
       info.base_finalize = NULL;
       info.class_init = (GClassInitFunc)(&ada_class_record_init);
       info.class_finalize = NULL;
       info.class_data = (gconstpointer)klass;
       info.instance_size = query.instance_size;
       info.n_preallocs = 0;
       info.instance_init = NULL;
       info.value_table = NULL;

       GType new_type = g_type_register_static (
             ancestor  /* parent_type */,
             type_name /* type_name */,
             &info     /* info */,
             0         /* flags */);

       /*************************
        * This code is generally called by g_object_new (which itself is called
        * from type_name_new() in C). Its result is to create and initialized
        * (via class_init) the class the first time an instance of it is
        * created. In Ada, we do not us a _class_init, so we initialize the
        * signals immediately after creating the class.
        *************************/

       for (j = 0; j < nsignals; j++) {
          int count = 0;
          GClosure *closure;

          while (count < max_parameters &&
                  (parameters [j * max_parameters + count] != G_TYPE_NONE))
          {
                count++;
          }

          closure = g_signal_type_cclosure_new
              (new_type, query.class_size + j * sizeof (void*)); /* offset */

          GType return_type = G_TYPE_NONE;
          GSignalAccumulator acc = NULL;

          if (j < max_returns) {
             return_type = returns[j];
             if (return_type == G_TYPE_BOOLEAN) {
                acc = g_signal_accumulator_true_handled;
             }
          }

          /* id = */ g_signal_newv
            (signals[j],                       /* signal_name */
             new_type,                         /* itype */
             G_SIGNAL_RUN_LAST,                /* signal_flags */
             closure,                          /* class_closure */
             acc,                              /* accumulator */
             NULL,                             /* accu_data */
             g_cclosure_marshal_VOID__VOID,    /* c_marshaller, unused at the
               Ada level ??? This probably makes the widget unusable from C */
             return_type,                      /* return_type */
             count,                            /* n_params */
             parameters + j * max_parameters); /* param_types */
       }

       /* Do not call g_type_class_ref here, since that would prevent us
        * from adding interfaces later on. Instead, rely on the class_init
        * function
        */
       g_once_init_leave (&klass->type, new_type); // sets klass->type
       return 1;
   }
   return 0;
}
コード例 #26
0
ファイル: gum.c プロジェクト: frida/frida-gum
static void
gum_on_log_message (const gchar * log_domain,
                    GLogLevelFlags log_level,
                    const gchar * message,
                    gpointer user_data)
{
#if defined (HAVE_WINDOWS)
  gunichar2 * message_utf16;

  message_utf16 = g_utf8_to_utf16 (message, -1, NULL, NULL, NULL);
  OutputDebugString (message_utf16);
  g_free (message_utf16);
#elif defined (HAVE_ANDROID)
  int priority;

  switch (log_level & G_LOG_LEVEL_MASK)
  {
    case G_LOG_LEVEL_ERROR:
    case G_LOG_LEVEL_CRITICAL:
    case G_LOG_LEVEL_WARNING:
      priority = ANDROID_LOG_FATAL;
      break;
    case G_LOG_LEVEL_MESSAGE:
    case G_LOG_LEVEL_INFO:
      priority = ANDROID_LOG_INFO;
      break;
    case G_LOG_LEVEL_DEBUG:
    default:
      priority = ANDROID_LOG_DEBUG;
      break;
  }

  __android_log_write (priority, log_domain, message);
#else
# ifdef HAVE_DARWIN
  static gsize api_value = 0;
  GumCFApi * api;

  if (g_once_init_enter (&api_value))
  {
    const gchar * cf_path = "/System/Library/Frameworks/"
        "CoreFoundation.framework/CoreFoundation";
    void * cf;

    /*
     * CoreFoundation must be loaded by the main thread, so we should avoid
     * loading it.
     */
    if (gum_module_find_base_address (cf_path) != 0)
    {
      cf = dlopen (cf_path, RTLD_GLOBAL | RTLD_LAZY);
      g_assert (cf != NULL);

      api = g_slice_new (GumCFApi);

      api->CFStringCreateWithCString = dlsym (cf, "CFStringCreateWithCString");
      g_assert (api->CFStringCreateWithCString != NULL);

      api->CFRelease = dlsym (cf, "CFRelease");
      g_assert (api->CFRelease != NULL);

      api->CFLog = dlsym (cf, "CFLog");
      g_assert (api->CFLog != NULL);

      dlclose (cf);
    }
    else
    {
      api = NULL;
    }

    g_once_init_leave (&api_value, 1 + GPOINTER_TO_SIZE (api));
  }

  api = GSIZE_TO_POINTER (api_value - 1);
  if (api != NULL)
  {
    CFLogLevel cf_log_level;
    CFStringRef message_str, template_str;

    switch (log_level & G_LOG_LEVEL_MASK)
    {
      case G_LOG_LEVEL_ERROR:
        cf_log_level = kCFLogLevelError;
        break;
      case G_LOG_LEVEL_CRITICAL:
        cf_log_level = kCFLogLevelCritical;
        break;
      case G_LOG_LEVEL_WARNING:
        cf_log_level = kCFLogLevelWarning;
        break;
      case G_LOG_LEVEL_MESSAGE:
        cf_log_level = kCFLogLevelNotice;
        break;
      case G_LOG_LEVEL_INFO:
        cf_log_level = kCFLogLevelInfo;
        break;
      case G_LOG_LEVEL_DEBUG:
        cf_log_level = kCFLogLevelDebug;
        break;
      default:
        g_assert_not_reached ();
    }

    message_str = api->CFStringCreateWithCString (NULL, message,
        kCFStringEncodingUTF8);
    if (log_domain != NULL)
    {
      CFStringRef log_domain_str;

      template_str = api->CFStringCreateWithCString (NULL, "%@: %@",
          kCFStringEncodingUTF8);
      log_domain_str = api->CFStringCreateWithCString (NULL, log_domain,
          kCFStringEncodingUTF8);
      api->CFLog (cf_log_level, template_str, log_domain_str, message_str);
      api->CFRelease (log_domain_str);
    }
    else
    {
      template_str = api->CFStringCreateWithCString (NULL, "%@",
          kCFStringEncodingUTF8);
      api->CFLog (cf_log_level, template_str, message_str);
    }
    api->CFRelease (template_str);
    api->CFRelease (message_str);

    return;
  }
  /* else: fall through to stdout/stderr logging */
# endif

  FILE * file = NULL;
  const gchar * severity = NULL;

  switch (log_level & G_LOG_LEVEL_MASK)
  {
    case G_LOG_LEVEL_ERROR:
      file = stderr;
      severity = "ERROR";
      break;
    case G_LOG_LEVEL_CRITICAL:
      file = stderr;
      severity = "CRITICAL";
      break;
    case G_LOG_LEVEL_WARNING:
      file = stderr;
      severity = "WARNING";
      break;
    case G_LOG_LEVEL_MESSAGE:
      file = stderr;
      severity = "MESSAGE";
      break;
    case G_LOG_LEVEL_INFO:
      file = stdout;
      severity = "INFO";
      break;
    case G_LOG_LEVEL_DEBUG:
      file = stdout;
      severity = "DEBUG";
      break;
    default:
      g_assert_not_reached ();
  }

  fprintf (file, "[%s %s] %s\n", log_domain, severity, message);
  fflush (file);
#endif
}
コード例 #27
0
ファイル: fragment-util.c プロジェクト: GNOME/gupnp-av
static gboolean
is_read_only (const gchar *changed_element,
              const gchar *changed_attribute)
{
        static GHashTable *readonly_props = NULL;
        static gsize readonly_props_loaded = 0;

        if (g_once_init_enter (&readonly_props_loaded)) {
                readonly_props = g_hash_table_new (g_str_hash,
                                                   g_str_equal);

                hash_table_add (readonly_props, (gpointer)  "@id");
                hash_table_add (readonly_props, (gpointer)  "@parentID");
                hash_table_add (readonly_props, (gpointer)  "@refID");
                hash_table_add (readonly_props, (gpointer)  "@restricted");
                hash_table_add (readonly_props, (gpointer)  "@searchable");
                hash_table_add (readonly_props, (gpointer)  "@childCount");
                hash_table_add (readonly_props, (gpointer)  "searchClass");
                hash_table_add (readonly_props, (gpointer)  "[email protected]");
                hash_table_add (readonly_props, (gpointer)  "[email protected]");
                hash_table_add (readonly_props, (gpointer)  "createClass");
                hash_table_add (readonly_props, (gpointer)  "[email protected]");
                hash_table_add (readonly_props, (gpointer)  "[email protected]");
                hash_table_add (readonly_props, (gpointer)  "writeStatus");
                hash_table_add (readonly_props, (gpointer)  "[email protected]");
                hash_table_add (readonly_props, (gpointer)  "storageTotal");
                hash_table_add (readonly_props, (gpointer)  "storageUsed");
                hash_table_add (readonly_props, (gpointer)  "storageFree");
                hash_table_add (readonly_props, (gpointer)  "storageMaxPartition");
                hash_table_add (readonly_props, (gpointer)  "storageMedium");
                hash_table_add (readonly_props, (gpointer)  "playbackCount");
                hash_table_add (readonly_props, (gpointer)  "srsRecordScheduleID");
                hash_table_add (readonly_props, (gpointer)  "srsRecordTaskID");
                hash_table_add (readonly_props, (gpointer)  "price");
                hash_table_add (readonly_props, (gpointer)  "[email protected]");
                hash_table_add (readonly_props, (gpointer)  "payPerView");
                hash_table_add (readonly_props, (gpointer)  "dateTimeRange");
                hash_table_add (readonly_props, (gpointer)
                                "[email protected]");
                hash_table_add (readonly_props, (gpointer)  "signalStrength");
                hash_table_add (readonly_props, (gpointer)  "signalLocked");
                hash_table_add (readonly_props, (gpointer)  "tuned");
                hash_table_add (readonly_props, (gpointer)  "containerUpdateID");
                hash_table_add (readonly_props, (gpointer)  "objectUpdateID");
                hash_table_add (readonly_props, (gpointer)  "totalDeletedChildCount");
                hash_table_add (readonly_props, (gpointer)  "[email protected]");
                g_once_init_leave (&readonly_props_loaded, 1);
        }
        if (changed_element != NULL) {
                if (changed_attribute != NULL) {
                        gchar *test_prop = g_strdup_printf ("%[email protected]%s",
                                                            changed_element,
                                                            changed_attribute);
                        gboolean result = hash_table_contains (readonly_props,
                                                               test_prop);

                        g_free (test_prop);
                        if (result)
                                return TRUE;
                        test_prop = g_strdup_printf ("@%s", changed_attribute);
                        result = hash_table_contains (readonly_props,
                                                      test_prop);
                        g_free (test_prop);
                        if (result)
                                return TRUE;
                }

                return hash_table_contains (readonly_props, changed_element);
        }

        return FALSE;
}
コード例 #28
0
GType
gst_rtsp_status_code_get_type (void)
{
  static volatile gsize g_define_type_id__volatile = 0;
  if (g_once_init_enter (&g_define_type_id__volatile)) {
    static const GEnumValue values[] = {
      {GST_RTSP_STS_INVALID, "GST_RTSP_STS_INVALID", "invalid"},
      {GST_RTSP_STS_CONTINUE, "GST_RTSP_STS_CONTINUE", "continue"},
      {GST_RTSP_STS_OK, "GST_RTSP_STS_OK", "ok"},
      {GST_RTSP_STS_CREATED, "GST_RTSP_STS_CREATED", "created"},
      {GST_RTSP_STS_LOW_ON_STORAGE, "GST_RTSP_STS_LOW_ON_STORAGE",
          "low-on-storage"},
      {GST_RTSP_STS_MULTIPLE_CHOICES, "GST_RTSP_STS_MULTIPLE_CHOICES",
          "multiple-choices"},
      {GST_RTSP_STS_MOVED_PERMANENTLY, "GST_RTSP_STS_MOVED_PERMANENTLY",
          "moved-permanently"},
      {GST_RTSP_STS_MOVE_TEMPORARILY, "GST_RTSP_STS_MOVE_TEMPORARILY",
          "move-temporarily"},
      {GST_RTSP_STS_SEE_OTHER, "GST_RTSP_STS_SEE_OTHER", "see-other"},
      {GST_RTSP_STS_NOT_MODIFIED, "GST_RTSP_STS_NOT_MODIFIED", "not-modified"},
      {GST_RTSP_STS_USE_PROXY, "GST_RTSP_STS_USE_PROXY", "use-proxy"},
      {GST_RTSP_STS_BAD_REQUEST, "GST_RTSP_STS_BAD_REQUEST", "bad-request"},
      {GST_RTSP_STS_UNAUTHORIZED, "GST_RTSP_STS_UNAUTHORIZED", "unauthorized"},
      {GST_RTSP_STS_PAYMENT_REQUIRED, "GST_RTSP_STS_PAYMENT_REQUIRED",
          "payment-required"},
      {GST_RTSP_STS_FORBIDDEN, "GST_RTSP_STS_FORBIDDEN", "forbidden"},
      {GST_RTSP_STS_NOT_FOUND, "GST_RTSP_STS_NOT_FOUND", "not-found"},
      {GST_RTSP_STS_METHOD_NOT_ALLOWED, "GST_RTSP_STS_METHOD_NOT_ALLOWED",
          "method-not-allowed"},
      {GST_RTSP_STS_NOT_ACCEPTABLE, "GST_RTSP_STS_NOT_ACCEPTABLE",
          "not-acceptable"},
      {GST_RTSP_STS_PROXY_AUTH_REQUIRED, "GST_RTSP_STS_PROXY_AUTH_REQUIRED",
          "proxy-auth-required"},
      {GST_RTSP_STS_REQUEST_TIMEOUT, "GST_RTSP_STS_REQUEST_TIMEOUT",
          "request-timeout"},
      {GST_RTSP_STS_GONE, "GST_RTSP_STS_GONE", "gone"},
      {GST_RTSP_STS_LENGTH_REQUIRED, "GST_RTSP_STS_LENGTH_REQUIRED",
          "length-required"},
      {GST_RTSP_STS_PRECONDITION_FAILED, "GST_RTSP_STS_PRECONDITION_FAILED",
          "precondition-failed"},
      {GST_RTSP_STS_REQUEST_ENTITY_TOO_LARGE,
            "GST_RTSP_STS_REQUEST_ENTITY_TOO_LARGE",
          "request-entity-too-large"},
      {GST_RTSP_STS_REQUEST_URI_TOO_LARGE, "GST_RTSP_STS_REQUEST_URI_TOO_LARGE",
          "request-uri-too-large"},
      {GST_RTSP_STS_UNSUPPORTED_MEDIA_TYPE,
          "GST_RTSP_STS_UNSUPPORTED_MEDIA_TYPE", "unsupported-media-type"},
      {GST_RTSP_STS_PARAMETER_NOT_UNDERSTOOD,
            "GST_RTSP_STS_PARAMETER_NOT_UNDERSTOOD",
          "parameter-not-understood"},
      {GST_RTSP_STS_CONFERENCE_NOT_FOUND, "GST_RTSP_STS_CONFERENCE_NOT_FOUND",
          "conference-not-found"},
      {GST_RTSP_STS_NOT_ENOUGH_BANDWIDTH, "GST_RTSP_STS_NOT_ENOUGH_BANDWIDTH",
          "not-enough-bandwidth"},
      {GST_RTSP_STS_SESSION_NOT_FOUND, "GST_RTSP_STS_SESSION_NOT_FOUND",
          "session-not-found"},
      {GST_RTSP_STS_METHOD_NOT_VALID_IN_THIS_STATE,
            "GST_RTSP_STS_METHOD_NOT_VALID_IN_THIS_STATE",
          "method-not-valid-in-this-state"},
      {GST_RTSP_STS_HEADER_FIELD_NOT_VALID_FOR_RESOURCE,
            "GST_RTSP_STS_HEADER_FIELD_NOT_VALID_FOR_RESOURCE",
          "header-field-not-valid-for-resource"},
      {GST_RTSP_STS_INVALID_RANGE, "GST_RTSP_STS_INVALID_RANGE",
          "invalid-range"},
      {GST_RTSP_STS_PARAMETER_IS_READONLY, "GST_RTSP_STS_PARAMETER_IS_READONLY",
          "parameter-is-readonly"},
      {GST_RTSP_STS_AGGREGATE_OPERATION_NOT_ALLOWED,
            "GST_RTSP_STS_AGGREGATE_OPERATION_NOT_ALLOWED",
          "aggregate-operation-not-allowed"},
      {GST_RTSP_STS_ONLY_AGGREGATE_OPERATION_ALLOWED,
            "GST_RTSP_STS_ONLY_AGGREGATE_OPERATION_ALLOWED",
          "only-aggregate-operation-allowed"},
      {GST_RTSP_STS_UNSUPPORTED_TRANSPORT, "GST_RTSP_STS_UNSUPPORTED_TRANSPORT",
          "unsupported-transport"},
      {GST_RTSP_STS_DESTINATION_UNREACHABLE,
          "GST_RTSP_STS_DESTINATION_UNREACHABLE", "destination-unreachable"},
      {GST_RTSP_STS_INTERNAL_SERVER_ERROR, "GST_RTSP_STS_INTERNAL_SERVER_ERROR",
          "internal-server-error"},
      {GST_RTSP_STS_NOT_IMPLEMENTED, "GST_RTSP_STS_NOT_IMPLEMENTED",
          "not-implemented"},
      {GST_RTSP_STS_BAD_GATEWAY, "GST_RTSP_STS_BAD_GATEWAY", "bad-gateway"},
      {GST_RTSP_STS_SERVICE_UNAVAILABLE, "GST_RTSP_STS_SERVICE_UNAVAILABLE",
          "service-unavailable"},
      {GST_RTSP_STS_GATEWAY_TIMEOUT, "GST_RTSP_STS_GATEWAY_TIMEOUT",
          "gateway-timeout"},
      {GST_RTSP_STS_RTSP_VERSION_NOT_SUPPORTED,
            "GST_RTSP_STS_RTSP_VERSION_NOT_SUPPORTED",
          "rtsp-version-not-supported"},
      {GST_RTSP_STS_OPTION_NOT_SUPPORTED, "GST_RTSP_STS_OPTION_NOT_SUPPORTED",
          "option-not-supported"},
      {0, NULL, NULL}
    };
    GType g_define_type_id =
        g_enum_register_static ("GstRTSPStatusCode", values);
    g_once_init_leave (&g_define_type_id__volatile, g_define_type_id);
  }
  return g_define_type_id__volatile;
}