static void gf_isom_meta_track_remove(GF_ISOFile *movie, GF_TrackBox *trak, u32 sample_number)
{
	u32 i, count;
	if (!movie || !movie->meta || !movie->meta->use_item_sample_sharing)
		return;

	count = gf_list_count(movie->meta->item_locations->location_entries);
	for (i=0; i<count; i++) {
		u32 j;
		GF_ItemLocationEntry *iloc = (GF_ItemLocationEntry *)gf_list_get(movie->meta->item_locations->location_entries, i);
		/*get item info*/
		GF_ItemInfoEntryBox *iinf = NULL;
		j=0;
		while ((iinf = (GF_ItemInfoEntryBox *)gf_list_enum(movie->meta->item_infos->item_infos, &j))) {
			if (iinf->item_ID==iloc->item_ID) break;
		}
		if (!iinf || !iinf->tk_id) continue;
		if (iinf->tk_id != trak->Header->trackID) continue;

		if (sample_number && (iinf->sample_num != sample_number)) continue;
		iinf->tk_id = 0;
		iinf->sample_num = 0;
	}
}
static void gf_isom_meta_track_remove(GF_ISOFile *movie, GF_TrackBox *trak, u32 sample_number)
{
	u32 i, count;
	if (!movie || !movie->meta || !movie->meta->use_item_sample_sharing)
		return;

	count = gf_list_count(movie->meta->item_locations->location_entries);
	for (i=0; i<count; i++) {
		u32 j;
		GF_ItemLocationEntry *iloc = (GF_ItemLocationEntry *)gf_list_get(movie->meta->item_locations->location_entries, i);
		 
		GF_ItemInfoEntryBox *iinf = NULL;
		j=0;
		while ((iinf = (GF_ItemInfoEntryBox *)gf_list_enum(movie->meta->item_infos->item_infos, &j))) {
			if (iinf->item_ID==iloc->item_ID) break;
		}
		if (!iinf || !iinf->tk_id) continue;
		if (iinf->tk_id != trak->Header->trackID) continue;

		if (sample_number && (iinf->sample_num != sample_number)) continue;
		iinf->tk_id = 0;
		iinf->sample_num = 0;
	}
}