[Bug 708914] Add openni2 plugin and openni2src element
GStreamer (bugzilla.gnome.org)
bugzilla at gnome.org
Wed Nov 6 07:38:24 PST 2013
https://bugzilla.gnome.org/show_bug.cgi?id=708914
GStreamer | gst-plugins-bad | unspecified
Sebastian Dröge (slomo) <slomo> changed:
What |Removed |Added
----------------------------------------------------------------------------
Attachment #259053|none |needs-work
status| |
--- Comment #11 from Sebastian Dröge (slomo) <slomo at coaxion.net> 2013-11-06 15:38:15 UTC ---
Review of attachment 259053:
--> (https://bugzilla.gnome.org/review?bug=708914&attachment=259053)
Remove the common change from the patch
::: ext/openni2/gstopenni2src.cpp
@@ +70,3 @@
+#define DEFAULT_SOURCETYPE SOURCETYPE_DEPTH
+
+#define SAMPLE_READ_WAIT_TIMEOUT 2000 //2000ms
No // comments, use /* */ comments
@@ +307,3 @@
+ GstCaps *ret;
+ ni2src = GST_OPENNI2_SRC (src);
+ if (ni2src->gst_caps)
This is racy btw, you need to lock access to ni2src->gst_caps
@@ +553,3 @@
+ data = (guint8*) g_malloc(framesize);
+ ni2src_buffer_as_gst_memory =
gst_memory_new_wrapped(GST_MEMORY_FLAG_READONLY,
+ data, framesize, 0, framesize, data, g_free);
You can also just use memory = gst_allocator_alloc (NULL, framesize, NULL);
instead of that. Or just use gst_buffer_new_and_alloc()
But why readonly? Also you need to be careful with the strides, maybe they're
not the same for openni and GStreamer.
@@ +559,3 @@
+ /* Add depth as 8bit alpha channel, depth is 16bit samples */
+ guint16* pDepth = (guint16*) src->depthFrame.getData();
+ for( int i=0; i < src->depthFrame.getDataSize()/2; ++i)
Why divided by 2?
--
Configure bugmail: https://bugzilla.gnome.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.
More information about the gstreamer-bugs
mailing list