<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Depth Stream is not Working in Software Archive</title>
    <link>https://community.intel.com/t5/Software-Archive/Depth-Stream-is-not-Working/m-p/1045230#M47667</link>
    <description>&lt;P style="font-size: 12px;"&gt;hi,&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;i converted depth stream into mat variable in opencv.&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;when i run the code it runs successfully. but nothing is shown in the screen. and after few second the screen become black.&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;I am not able to figure out what mistake i am doing.&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;below is the code :&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;int wmain(int argc, WCHAR* argv[])&amp;nbsp;&lt;BR /&gt;
	{&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;//Create the IplImage headers&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;IplImage* depthimg = cvCreateImageHeader(cvSize(320, 240), 16, 1);&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;// create the PXCSenseManager&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;PXCSenseManager *psm=0;&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;psm = PXCSenseManager::CreateInstance();&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;if (!psm) {&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;wprintf_s(L"Unable to create the PXCSenseManager\n");&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;return 1;&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;}&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;// select the color stream of size 640x480 and depth stream of size 320x240&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;psm-&amp;gt;EnableStream(PXCCapture::STREAM_TYPE_DEPTH, 640, 480);&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;// initialize the PXCSenseManager&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;if(psm-&amp;gt;Init() != PXC_STATUS_NO_ERROR) return 2;&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;PXCImage *colorIm, *depthIm;&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;for (int i=0; i&amp;lt;MAX_FRAMES; i++)&amp;nbsp;&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;{&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;if (psm-&amp;gt;AcquireFrame(true)&amp;lt;PXC_STATUS_NO_ERROR) break;&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;// retrieve all available image samples&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;PXCCapture::Sample *sample = psm-&amp;gt;QuerySample();&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;// retrieve the image or frame by type from the sample&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;depthIm = sample-&amp;gt;depth;&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;PXCImage *depth_image = depthIm;&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;PXCImage::ImageData depthImageData;&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;depth_image-&amp;gt;AcquireAccess( PXCImage::ACCESS_READ, &amp;amp;depthImageData );&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;cvSetData( depthimg, (short*)depthImageData.planes[0], depthimg-&amp;gt;width * sizeof(short) );&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;Mat depthMat(depthimg );&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;imshow( "depth", depthMat );&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;depth_image-&amp;gt;ReleaseAccess(&amp;amp;depthImageData);&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;}&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;waitKey();&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;}&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;thanks !!&lt;/P&gt;</description>
    <pubDate>Fri, 09 Jan 2015 12:02:26 GMT</pubDate>
    <dc:creator>Deepak_k_</dc:creator>
    <dc:date>2015-01-09T12:02:26Z</dc:date>
    <item>
      <title>Depth Stream is not Working</title>
      <link>https://community.intel.com/t5/Software-Archive/Depth-Stream-is-not-Working/m-p/1045230#M47667</link>
      <description>&lt;P style="font-size: 12px;"&gt;hi,&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;i converted depth stream into mat variable in opencv.&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;when i run the code it runs successfully. but nothing is shown in the screen. and after few second the screen become black.&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;I am not able to figure out what mistake i am doing.&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;below is the code :&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;int wmain(int argc, WCHAR* argv[])&amp;nbsp;&lt;BR /&gt;
	{&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;//Create the IplImage headers&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;IplImage* depthimg = cvCreateImageHeader(cvSize(320, 240), 16, 1);&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;// create the PXCSenseManager&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;PXCSenseManager *psm=0;&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;psm = PXCSenseManager::CreateInstance();&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;if (!psm) {&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;wprintf_s(L"Unable to create the PXCSenseManager\n");&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;return 1;&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;}&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;// select the color stream of size 640x480 and depth stream of size 320x240&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;psm-&amp;gt;EnableStream(PXCCapture::STREAM_TYPE_DEPTH, 640, 480);&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;// initialize the PXCSenseManager&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;if(psm-&amp;gt;Init() != PXC_STATUS_NO_ERROR) return 2;&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;PXCImage *colorIm, *depthIm;&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;for (int i=0; i&amp;lt;MAX_FRAMES; i++)&amp;nbsp;&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;{&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;if (psm-&amp;gt;AcquireFrame(true)&amp;lt;PXC_STATUS_NO_ERROR) break;&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;// retrieve all available image samples&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;PXCCapture::Sample *sample = psm-&amp;gt;QuerySample();&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;// retrieve the image or frame by type from the sample&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;depthIm = sample-&amp;gt;depth;&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;PXCImage *depth_image = depthIm;&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;PXCImage::ImageData depthImageData;&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;depth_image-&amp;gt;AcquireAccess( PXCImage::ACCESS_READ, &amp;amp;depthImageData );&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;cvSetData( depthimg, (short*)depthImageData.planes[0], depthimg-&amp;gt;width * sizeof(short) );&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;Mat depthMat(depthimg );&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;imshow( "depth", depthMat );&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;depth_image-&amp;gt;ReleaseAccess(&amp;amp;depthImageData);&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;}&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;waitKey();&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;}&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;&amp;nbsp;&lt;/P&gt;

&lt;P style="font-size: 12px;"&gt;thanks !!&lt;/P&gt;</description>
      <pubDate>Fri, 09 Jan 2015 12:02:26 GMT</pubDate>
      <guid>https://community.intel.com/t5/Software-Archive/Depth-Stream-is-not-Working/m-p/1045230#M47667</guid>
      <dc:creator>Deepak_k_</dc:creator>
      <dc:date>2015-01-09T12:02:26Z</dc:date>
    </item>
  </channel>
</rss>

