vaapidecode to xvimagesink

rrazavi reza at userful.com
Tue Jan 28 08:48:44 PST 2014


I have written a small code and up to derive image everything is fine but the
data that I receive for each frame is :
Width= 1920 Height=816  Data size 2396160---video/x-raw, format=(string)NV12

The data size is bigger than it should be and it's for a 1920X832 video
which looks like hardware limitation for lintel GPU.
When I pass these frames to another pipeline with apsrc the output is not
correct.

I'm running 2 pipelines :
pipeline1= filesrc location=\"%s\" ! qtdemux ! h264parse ! appsink
max-buffers=10 drop=true name=\"%s\"
pipeline2= appsrc name=\"%s\" ! queue ! videoparse width=1920 height=816 !
xvimagesink display=:2

and for appsink call back after gst_vaapi_surface_derive_image(surface) I
have :

if(VaImg != NULL)
{
	IMsize=gst_vaapi_image_get_data_size(VaImg);
	GstAllocator *allocator;
	outbuf=gst_buffer_new_allocate (allocator,IMsize,NULL);
	if (gst_buffer_map (outbuf, &info,(GstMapFlags)(GST_MAP_READ)) == FALSE) {
		g_warning ("Error mapping GStreamer memory");
	}
	gst_vaapi_image_map(VaImg);
	memcpy(info.data, gst_vaapi_image_get_plane(VaImg,0), IMsize);
	gst_vaapi_image_unmap(VaImg);
	gst_app_src_push_buffer( GST_APP_SRC(
gst_bin_get_by_name(GST_BIN(pipeline2),app_src_name)) , outbuf);
	gst_buffer_unmap(outbuf, &info);
	gst_vaapi_object_unref(VaImg);
}

Gstreamer VAAPI version is 5.8 and CPU is core i7-4770S with Intel® HD
Graphics 4600 graphics





--
View this message in context: http://gstreamer-devel.966125.n4.nabble.com/vaapidecode-to-xvimagesink-tp4664635p4664942.html
Sent from the GStreamer-devel mailing list archive at Nabble.com.


More information about the gstreamer-devel mailing list