Example #1
0
void soy_scenes_td_side_unset2d (soyscenesTDSide* self, soybodiesBody* body) {
	GeeLinkedList* _tmp0_ = NULL;
	soybodiesBody* _tmp1_ = NULL;
	GeeHashMap* _tmp2_ = NULL;
	soybodiesBody* _tmp3_ = NULL;
#line 51 "/home/jeff/Documents/libraries/libsoy/src/scenes/TDSide.gs"
	g_return_if_fail (self != NULL);
#line 51 "/home/jeff/Documents/libraries/libsoy/src/scenes/TDSide.gs"
	g_return_if_fail (body != NULL);
#line 52 "/home/jeff/Documents/libraries/libsoy/src/scenes/TDSide.gs"
	_tmp0_ = self->tdbodies;
#line 52 "/home/jeff/Documents/libraries/libsoy/src/scenes/TDSide.gs"
	_tmp1_ = body;
#line 52 "/home/jeff/Documents/libraries/libsoy/src/scenes/TDSide.gs"
	gee_abstract_collection_remove ((GeeAbstractCollection*) _tmp0_, _tmp1_);
#line 53 "/home/jeff/Documents/libraries/libsoy/src/scenes/TDSide.gs"
	_tmp2_ = self->plane2ds;
#line 53 "/home/jeff/Documents/libraries/libsoy/src/scenes/TDSide.gs"
	_tmp3_ = body;
#line 53 "/home/jeff/Documents/libraries/libsoy/src/scenes/TDSide.gs"
	gee_abstract_map_unset ((GeeAbstractMap*) _tmp2_, _tmp3_, NULL);
#line 391 "TDSide.c"
}
static void
rygel_media_export_metadata_extractor_on_done (RygelMediaExportMetadataExtractor *self,
                                               GstDiscovererInfo                 *gst_info,
                                               GError                            *err) {
  RygelMediaExportMetadataExtractorPrivate *priv;
  guint signal_id;
  const gchar *uri;
  GeeAbstractMap *abstract_file_hash;
  GstDiscovererResult result;
  GFile *file;

  g_return_if_fail (RYGEL_MEDIA_EXPORT_IS_METADATA_EXTRACTOR (self));
  g_return_if_fail (GST_IS_DISCOVERER_INFO (gst_info));

  priv = self->priv;
  signal_id = 0;
  g_signal_parse_name ("discovered", GST_TYPE_DISCOVERER, &signal_id, NULL, FALSE);
  g_signal_handlers_disconnect_matched (priv->discoverer,
                                        G_SIGNAL_MATCH_ID |
                                        G_SIGNAL_MATCH_FUNC |
                                        G_SIGNAL_MATCH_DATA, signal_id,
                                        0,
                                        NULL,
                                        G_CALLBACK (rygel_media_export_metadata_extractor_on_done_gst_discoverer_discovered),
                                        self);

  g_object_unref (priv->discoverer);
  priv->discoverer = NULL;

  uri = gst_discoverer_info_get_uri (gst_info);
  abstract_file_hash = GEE_ABSTRACT_MAP (priv->file_hash);
  file = G_FILE (gee_abstract_map_get (abstract_file_hash, uri));
  if (!file) {
    g_warning ("File %s already handled, ignoring event", uri);
    return;
  }
  gee_abstract_map_unset (abstract_file_hash, uri, NULL);
  result = gst_discoverer_info_get_result (gst_info);

  if ((result & GST_DISCOVERER_ERROR) == GST_DISCOVERER_ERROR) {
    g_signal_emit (self, signals[ERROR], 0, file, err);
  } else {
    GUPnPDLNAProfile *dlna_profile;

    if ((result & GST_DISCOVERER_TIMEOUT) == GST_DISCOVERER_TIMEOUT) {
      gchar* file_uri = g_file_get_uri (file);

      g_debug ("Extraction timed out on %s", file_uri);
      g_free (file_uri);
      dlna_profile = NULL;
    } else {
      GUPnPDLNAInformation *dlna_info = gupnp_dlna_gst_utils_information_from_discoverer_info (gst_info);

      dlna_profile = gupnp_dlna_profile_guesser_guess_profile_from_info (priv->guesser,
                                                                         dlna_info);
      g_object_unref (dlna_info);
    }

    rygel_media_export_metadata_extractor_extract_basic_information (self,
                                                                     file,
                                                                     gst_info,
                                                                     dlna_profile);
  }

  g_object_unref (file);
}
Example #3
0
static void _soy_textures_bumpmap_texel_weak (soytexturesBumpmap* self, GObject* vector) {
	GeeArrayList* _tmp0_;
	GeeArrayList* garbage;
	g_return_if_fail (self != NULL);
	g_return_if_fail (vector != NULL);
	_tmp0_ = gee_array_list_new (G_TYPE_INT, NULL, NULL, NULL);
	garbage = _tmp0_;
	{
		GeeHashMap* _tmp1_;
		GeeSet* _tmp2_;
		GeeSet* _tmp3_;
		GeeSet* _tmp4_;
		GeeIterator* _tmp5_ = NULL;
		GeeIterator* _tmp6_;
		GeeIterator* _index_it;
		_tmp1_ = self->priv->_texel_objs;
		_tmp2_ = gee_abstract_map_get_keys ((GeeMap*) _tmp1_);
		_tmp3_ = _tmp2_;
		_tmp4_ = _tmp3_;
		_tmp5_ = gee_iterable_iterator ((GeeIterable*) _tmp4_);
		_tmp6_ = _tmp5_;
		_g_object_unref0 (_tmp4_);
		_index_it = _tmp6_;
		while (TRUE) {
			GeeIterator* _tmp7_;
			gboolean _tmp8_ = FALSE;
			GeeIterator* _tmp9_;
			gpointer _tmp10_ = NULL;
			gint index;
			GeeHashMap* _tmp11_;
			gint _tmp12_;
			gpointer _tmp13_ = NULL;
			GObject* _tmp14_;
			_tmp7_ = _index_it;
			_tmp8_ = gee_iterator_next (_tmp7_);
			if (!_tmp8_) {
				break;
			}
			_tmp9_ = _index_it;
			_tmp10_ = gee_iterator_get (_tmp9_);
			index = (gint) ((gintptr) _tmp10_);
			_tmp11_ = self->priv->_texel_objs;
			_tmp12_ = index;
			_tmp13_ = gee_abstract_map_get ((GeeAbstractMap*) _tmp11_, (gpointer) ((gintptr) _tmp12_));
			_tmp14_ = vector;
			if (G_TYPE_CHECK_INSTANCE_CAST ((soyatomsVector*) _tmp13_, G_TYPE_OBJECT, GObject) == _tmp14_) {
				GeeArrayList* _tmp15_;
				gint _tmp16_;
				_tmp15_ = garbage;
				_tmp16_ = index;
				gee_abstract_collection_add ((GeeAbstractCollection*) _tmp15_, (gpointer) ((gintptr) _tmp16_));
			}
		}
		_g_object_unref0 (_index_it);
	}
	{
		GeeArrayList* _tmp17_;
		GeeArrayList* _tmp18_;
		GeeArrayList* _index_list;
		GeeArrayList* _tmp19_;
		gint _tmp20_;
		gint _tmp21_;
		gint _index_size;
		gint _index_index;
		_tmp17_ = garbage;
		_tmp18_ = _g_object_ref0 (_tmp17_);
		_index_list = _tmp18_;
		_tmp19_ = _index_list;
		_tmp20_ = gee_abstract_collection_get_size ((GeeCollection*) _tmp19_);
		_tmp21_ = _tmp20_;
		_index_size = _tmp21_;
		_index_index = -1;
		while (TRUE) {
			gint _tmp22_;
			gint _tmp23_;
			gint _tmp24_;
			GeeArrayList* _tmp25_;
			gint _tmp26_;
			gpointer _tmp27_ = NULL;
			gint index;
			GeeHashMap* _tmp28_;
			gint _tmp29_;
			_tmp22_ = _index_index;
			_index_index = _tmp22_ + 1;
			_tmp23_ = _index_index;
			_tmp24_ = _index_size;
			if (!(_tmp23_ < _tmp24_)) {
				break;
			}
			_tmp25_ = _index_list;
			_tmp26_ = _index_index;
			_tmp27_ = gee_abstract_list_get ((GeeAbstractList*) _tmp25_, _tmp26_);
			index = (gint) ((gintptr) _tmp27_);
			_tmp28_ = self->priv->_texel_objs;
			_tmp29_ = index;
			gee_abstract_map_unset ((GeeAbstractMap*) _tmp28_, (gpointer) ((gintptr) _tmp29_), NULL);
		}
		_g_object_unref0 (_index_list);
	}
	_g_object_unref0 (garbage);
}