From 1ccd01cd667e2c91a4802022e41a583d91d8840c Mon Sep 17 00:00:00 2001 From: Austin Yuan Date: Mon, 5 May 2008 17:30:11 -0400 Subject: [PATCH] Correct some mistakes in va.h --- src/va.h | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/src/va.h b/src/va.h index 0384f16..55f9a07 100755 --- a/src/va.h +++ b/src/va.h @@ -203,7 +203,7 @@ typedef enum VAEntrypointMoComp = 4, VAEntrypointDeblocking = 5, /* Encode entrypoints */ - VAEntrypointVLC = 6, /* slice level encode */ + VAEntrypointEncodeES = 6, /* slice level encode */ } VAEntrypoint; /* Currently defined configuration attribute types */ @@ -1837,7 +1837,7 @@ Mostly to demonstrate program flow with no error handling ... /* find out whether H.264 BP encode is supported */ VAProfile *profiles = malloc(sizeof(VAProfile)*max_num_profiles); int num_profiles; - vaQueryConfigProfiles(dpy, profiles, &profiles); + vaQueryConfigProfiles(dpy, profiles, &num_profiles); /* * traverse "profiles" to locate the one that matches VAProfileH264BP */ @@ -1849,11 +1849,12 @@ Mostly to demonstrate program flow with no error handling ... /* traverse "entrypoints" to see whether VLC is there */ - /* Assuming finding VLC, find out the format and rate control mode for the source */ - VAConfigAttrib attrib; - attrib.type = VAConfigAttribRTFormat; + /* Assuming finding VAEntrypointEncodeES, find out the format and rate control mode for the source */ + VAConfigAttrib attrib[2]; + attrib[0].type = VAConfigAttribRTFormat; + attrib[1].type = VAConfigAttribRateControl; vaGetConfigAttributes(dpy, VAProfileH264Baseline, VAEntrypointVLC, - &attrib, 1); + &attrib, 2); if (attrib[0].value & VA_RT_FORMAT_YUV420) /* Found desired format, keep going */ -- 2.7.4