<?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 Create PXCMImage in Java in Software Archive</title>
    <link>https://community.intel.com/t5/Software-Archive/Create-PXCMImage-in-Java/m-p/1081509#M61794</link>
    <description>&lt;P&gt;Hi guys.&lt;/P&gt;

&lt;P&gt;I tried to create the PXCMImage and followed this&lt;A href="https://software.intel.com/en-us/forums/realsense/topic/606341#comment-1857656"&gt; very good topic&lt;/A&gt;. But when i tryed to migrate te informatin to java, i received this message:&lt;/P&gt;

&lt;P&gt;#&lt;BR /&gt;
	# A fatal error has been detected by the Java Runtime Environment:&lt;BR /&gt;
	#&lt;BR /&gt;
	#&amp;nbsp; EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x00007ffa25b1e291, pid=5732, tid=5328&lt;BR /&gt;
	#&lt;BR /&gt;
	# JRE version: Java(TM) SE Runtime Environment (8.0_45-b15) (build 1.8.0_45-b15)&lt;BR /&gt;
	# Java VM: Java HotSpot(TM) 64-Bit Server VM (25.45-b02 mixed mode windows-amd64 compressed oops)&lt;BR /&gt;
	# Problematic frame:&lt;BR /&gt;
	# C&amp;nbsp; [libpxcclr.jni64.dll+0xe291]&lt;BR /&gt;
	#&lt;BR /&gt;
	# Failed to write core dump. Minidumps are not enabled by default on client versions of Windows&lt;BR /&gt;
	#&lt;BR /&gt;
	# An error report file with more information is saved as:&lt;BR /&gt;
	# D:\Dropbox\Mestrado\2016\workspace\TesteRealSence\hs_err_pid5732.log&lt;BR /&gt;
	#&lt;BR /&gt;
	# If you would like to submit a bug report, please visit:&lt;BR /&gt;
	#&amp;nbsp;&amp;nbsp; &lt;A href="http://bugreport.java.com/bugreport/crash.jsp" target="_blank"&gt;http://bugreport.java.com/bugreport/crash.jsp&lt;/A&gt;&lt;BR /&gt;
	# The crash happened outside the Java Virtual Machine in native code.&lt;BR /&gt;
	# See problematic frame for where to report the bug.&lt;BR /&gt;
	&amp;nbsp;&lt;/P&gt;

&lt;PRE class="brush:java;"&gt;below my code:&lt;/PRE&gt;

&lt;PRE class="brush:java;"&gt;&amp;nbsp;&lt;/PRE&gt;

&lt;PRE class="brush:java;"&gt;		byte[] arrayBytes = ImagemConvert.extractBytes("face.jpg");
		
		PXCMSession session = new PXCMSession();
		
		PXCMImage.ImageInfo imgInfo = new PXCMImage.ImageInfo();
		imgInfo.format = PXCMImage.PixelFormat.PIXEL_FORMAT_RGB32;
		imgInfo.width = 320;
		imgInfo.height = 400;
		
		PXCMImage.ImageData imgData = new PXCMImage.ImageData();
		imgData.format = PXCMImage.PixelFormat.PIXEL_FORMAT_RGB32;
		imgData.pitches[0]=(imgInfo.width*4); //This is because RGB32 is used (8bits * 4), change accordingly
		imgData.FromByteArray(0, arrayBytes);

		PXCMImage image = session.CreateImage(imgInfo, imgData);

		image.close();
		session.close();&lt;/PRE&gt;

&lt;DIV class="tw-swapa"&gt;
	&lt;DIV class="_wYb"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;/DIV&gt;

&lt;PRE class="tw-data-text vk_txt tw-ta tw-text-medium" data-fulltext="" data-placeholder="Tradução" dir="ltr" id="tw-target-text" style="text-align: left; height: 72px;"&gt;&lt;SPAN lang="en"&gt;Can anybody help me&lt;/SPAN&gt;&lt;/PRE&gt;

&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Sat, 09 Apr 2016 21:02:02 GMT</pubDate>
    <dc:creator>carlos_c_6</dc:creator>
    <dc:date>2016-04-09T21:02:02Z</dc:date>
    <item>
      <title>Create PXCMImage in Java</title>
      <link>https://community.intel.com/t5/Software-Archive/Create-PXCMImage-in-Java/m-p/1081509#M61794</link>
      <description>&lt;P&gt;Hi guys.&lt;/P&gt;

&lt;P&gt;I tried to create the PXCMImage and followed this&lt;A href="https://software.intel.com/en-us/forums/realsense/topic/606341#comment-1857656"&gt; very good topic&lt;/A&gt;. But when i tryed to migrate te informatin to java, i received this message:&lt;/P&gt;

&lt;P&gt;#&lt;BR /&gt;
	# A fatal error has been detected by the Java Runtime Environment:&lt;BR /&gt;
	#&lt;BR /&gt;
	#&amp;nbsp; EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x00007ffa25b1e291, pid=5732, tid=5328&lt;BR /&gt;
	#&lt;BR /&gt;
	# JRE version: Java(TM) SE Runtime Environment (8.0_45-b15) (build 1.8.0_45-b15)&lt;BR /&gt;
	# Java VM: Java HotSpot(TM) 64-Bit Server VM (25.45-b02 mixed mode windows-amd64 compressed oops)&lt;BR /&gt;
	# Problematic frame:&lt;BR /&gt;
	# C&amp;nbsp; [libpxcclr.jni64.dll+0xe291]&lt;BR /&gt;
	#&lt;BR /&gt;
	# Failed to write core dump. Minidumps are not enabled by default on client versions of Windows&lt;BR /&gt;
	#&lt;BR /&gt;
	# An error report file with more information is saved as:&lt;BR /&gt;
	# D:\Dropbox\Mestrado\2016\workspace\TesteRealSence\hs_err_pid5732.log&lt;BR /&gt;
	#&lt;BR /&gt;
	# If you would like to submit a bug report, please visit:&lt;BR /&gt;
	#&amp;nbsp;&amp;nbsp; &lt;A href="http://bugreport.java.com/bugreport/crash.jsp" target="_blank"&gt;http://bugreport.java.com/bugreport/crash.jsp&lt;/A&gt;&lt;BR /&gt;
	# The crash happened outside the Java Virtual Machine in native code.&lt;BR /&gt;
	# See problematic frame for where to report the bug.&lt;BR /&gt;
	&amp;nbsp;&lt;/P&gt;

&lt;PRE class="brush:java;"&gt;below my code:&lt;/PRE&gt;

&lt;PRE class="brush:java;"&gt;&amp;nbsp;&lt;/PRE&gt;

&lt;PRE class="brush:java;"&gt;		byte[] arrayBytes = ImagemConvert.extractBytes("face.jpg");
		
		PXCMSession session = new PXCMSession();
		
		PXCMImage.ImageInfo imgInfo = new PXCMImage.ImageInfo();
		imgInfo.format = PXCMImage.PixelFormat.PIXEL_FORMAT_RGB32;
		imgInfo.width = 320;
		imgInfo.height = 400;
		
		PXCMImage.ImageData imgData = new PXCMImage.ImageData();
		imgData.format = PXCMImage.PixelFormat.PIXEL_FORMAT_RGB32;
		imgData.pitches[0]=(imgInfo.width*4); //This is because RGB32 is used (8bits * 4), change accordingly
		imgData.FromByteArray(0, arrayBytes);

		PXCMImage image = session.CreateImage(imgInfo, imgData);

		image.close();
		session.close();&lt;/PRE&gt;

&lt;DIV class="tw-swapa"&gt;
	&lt;DIV class="_wYb"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;/DIV&gt;

&lt;PRE class="tw-data-text vk_txt tw-ta tw-text-medium" data-fulltext="" data-placeholder="Tradução" dir="ltr" id="tw-target-text" style="text-align: left; height: 72px;"&gt;&lt;SPAN lang="en"&gt;Can anybody help me&lt;/SPAN&gt;&lt;/PRE&gt;

&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 09 Apr 2016 21:02:02 GMT</pubDate>
      <guid>https://community.intel.com/t5/Software-Archive/Create-PXCMImage-in-Java/m-p/1081509#M61794</guid>
      <dc:creator>carlos_c_6</dc:creator>
      <dc:date>2016-04-09T21:02:02Z</dc:date>
    </item>
  </channel>
</rss>

