caps = gst_caps_from_string ("video/x-glitter,sparkling=True");
caps2 =
- gst_caps_from_string
- ("video/x-raw-yuv,width=640,height=480,framerate=15/1");
+ gst_caps_from_string ("video/x-raw,width=640,height=480,framerate=15/1");
sprof = (GstEncodingProfile *)
gst_encoding_video_profile_new (caps, "seriously glittery", caps2, 0);
gst_encoding_video_profile_set_variableframerate ((GstEncodingVideoProfile *)
fail_unless (gst_encoding_target_save (orig, NULL));
/* Check we can load it */
- profile_file_name = g_build_filename (g_get_home_dir (), ".gstreamer-0.10",
+ profile_file_name =
+ g_build_filename (g_get_user_data_dir (), "gstreamer-0.11",
"encoding-profiles", "herding", "myponytarget2.gep", NULL);
GST_DEBUG ("Loading target from '%s'", profile_file_name);
loaded = gst_encoding_target_load_from_file (profile_file_name, NULL);
GST_DEBUG ("Checking the container profile has the video//x-glitter stream");
tmpcaps = gst_caps_from_string ("video/x-glitter,sparkling=True");
tmpcaps2 =
- gst_caps_from_string
- ("video/x-raw-yuv,width=640,height=480,framerate=15/1");
+ gst_caps_from_string ("video/x-raw,width=640,height=480,framerate=15/1");
sprof2 = (GstEncodingProfile *)
gst_encoding_video_profile_new (tmpcaps, "seriously glittery", tmpcaps2,
0);
GstEncodingProfile *profile;
GstCaps *tmpcaps;
GValue strvalue = { 0, };
- GValue miniobjectvalue = { 0, };
+ GValue objectvalue = { 0, };
gst_debug_set_threshold_for_name ("default", GST_LEVEL_NONE);
gst_encoding_target_unref (target);
/* Test loading using fully specified path */
- profile_file_name = g_build_filename (g_get_home_dir (), ".gstreamer-0.10",
+ profile_file_name =
+ g_build_filename (g_get_user_data_dir (), "gstreamer-0.11",
"encoding-profiles", "herding", "myponytarget.gep", NULL);
GST_DEBUG ("Loading target from '%s'", profile_file_name);
/* For my next trick, I will need the assistance of a GValue */
g_value_init (&strvalue, G_TYPE_STRING);
- g_value_init (&miniobjectvalue, GST_TYPE_ENCODING_PROFILE);
+ g_value_init (&objectvalue, GST_TYPE_ENCODING_PROFILE);
g_value_set_static_string (&strvalue, "myponytarget/pony");
- fail_unless (g_value_transform (&strvalue, &miniobjectvalue));
- profile = (GstEncodingProfile *) gst_value_dup_mini_object (&miniobjectvalue);
+ fail_unless (g_value_transform (&strvalue, &objectvalue));
+ profile = (GstEncodingProfile *) g_value_dup_object (&objectvalue);
fail_if (profile == NULL);
g_value_unset (&strvalue);
- g_value_unset (&miniobjectvalue);
+ g_value_unset (&objectvalue);
tmpcaps = gst_caps_from_string ("animal/x-pony");
CHECK_PROFILE (profile, "pony", "I don't want a description !", tmpcaps, NULL,
0, 0);
/* If tmp is NULL, it means we iterated the whole list without finding
* our target */
fail_if (tmp == NULL);
- g_list_foreach (targets, (GFunc) gst_mini_object_unref, NULL);
+ g_list_foreach (targets, (GFunc) g_object_unref, NULL);
g_list_free (targets);
/* Try getting all available targets without a specified category */
/* If tmp is NULL, it means we iterated the whole list without finding
* our target */
fail_if (tmp == NULL);
- g_list_foreach (targets, (GFunc) gst_mini_object_unref, NULL);
+ g_list_foreach (targets, (GFunc) g_object_unref, NULL);
g_list_free (targets);
}
type=video\n\
preset=seriously glittery\n\
format=video/x-glitter,sparkling=True\n\
-restriction=video/x-raw-yuv,width=640,height=480,framerate=15/1\n\
+restriction=video/x-raw,width=640,height=480,framerate=15/1\n\
presence=0\n\
variableframerate=true\n\
";
{
gchar *profile_file_name;
- profile_file_name = g_build_filename (g_get_home_dir (), ".gstreamer-0.10",
+ profile_file_name =
+ g_build_filename (g_get_user_data_dir (), "gstreamer-0.11",
"encoding-profiles", "herding", "myponytarget.gep", NULL);
g_unlink (profile_file_name);
g_free (profile_file_name);
- profile_file_name = g_build_filename (g_get_home_dir (), ".gstreamer-0.10",
+ profile_file_name =
+ g_build_filename (g_get_user_data_dir (), "gstreamer-0.11",
"encoding-profiles", "herding", "myponytarget2.gep", NULL);
g_unlink (profile_file_name);
g_free (profile_file_name);
GError *error = NULL;
profile_dir =
- g_build_filename (g_get_home_dir (), ".gstreamer-0.10",
+ g_build_filename (g_get_user_data_dir (), "gstreamer-0.11",
"encoding-profiles", "herding", NULL);
profile_file_name =
- g_build_filename (g_get_home_dir (), ".gstreamer-0.10",
+ g_build_filename (g_get_user_data_dir (), "gstreamer-0.11",
"encoding-profiles", "herding", "myponytarget.gep", NULL);
g_mkdir_with_parents (profile_dir, S_IRUSR | S_IWUSR | S_IXUSR);
if (!g_file_set_contents (profile_file_name, profile_string,
gchar *gst_dir;
/* cehck if we can create profiles */
- gst_dir = g_build_filename (g_get_home_dir (), ".gstreamer-0.10", NULL);
+ gst_dir = g_build_filename (g_get_user_data_dir (), "gstreamer-0.11", NULL);
can_write = (g_access (gst_dir, R_OK | W_OK | X_OK) == 0);
g_free (gst_dir);