Items with no label
3335 Discussions

SetFileName Function dow

PKuma35
Beginner
1,660 Views

Hi Team,

I have been working with the new Intel Real Sense Camera SR 300 and the SDK Documentation 2016 R2 and R3.

 

However, the function SetFileName function does not seem to be working as per the documentation.

https://software.intel.com/sites/landingpage/realsense/camera-sdk/v2016r3/documentation/html/index.html?setfilename_pxccapturemanager.html https://software.intel.com/sites/landingpage/realsense/camera-sdk/v2016r3/documentation/html/index.html?setfilename_pxccapturemanager.html

They are supposed to create a file in the directory saving the stream of frames for Intel Stitching at a later point in time.

Please find my code snippet below:-

PXCMSenseManager pp = PXCMSenseManager.CreateInstance(); 

 

RaiseMessage("Starting...");

 

 

pp.EnableFace()

 

pp.Enable3DScan()

 

 

if (!string.IsNullOrEmpty(StreamOutputFilename))

 

{

 

if (File.Exists(StreamOutputFilename)) throw new Exception("File already exists");

 

 

{

 

System.Diagnostics.Debug.WriteLine(StreamOutputFilename);

 

pp.QueryCaptureManager().SetFileName(StreamOutputFilename,true);

I don't see any file created in the destination after initiating the function.

Kindly advice.

0 Kudos
12 Replies
idata
Employee
459 Views

Hi Praveen,

 

 

Thank you for your interest in the Intel® RealSense Technology.

 

 

I would like to know if you have tried the example in the Intel RealSense SDK to record and playback streaming sequences. Here you can find the example: https://software.intel.com/sites/landingpage/realsense/camera-sdk/v1.1/documentation/html/index.html?doc_essential_record_and_playback_streams.html https://software.intel.com/sites/landingpage/realsense/camera-sdk/v1.1/documentation/html/index.html?doc_essential_record_and_playback_streams.html.

 

 

Regards,

 

-Yermi A.

 

0 Kudos
PKuma35
Beginner
459 Views

Thanks for your reply, IntelCorporation YermiA_Intel .

I have not tried it yet, but I will make sure I try them!

Do you think that this could be an issue>

0 Kudos
idata
Employee
459 Views

Hi Praveen,

 

 

I was looking at the Intel RealSense SDK 2016 R3 documentation and I would like to share this link for the recording and playing back example: https://software.intel.com/sites/landingpage/realsense/camera-sdk/v2016r3/documentation/html/index.html?doc_essential_record_and_playback_streams.html https://software.intel.com/sites/landingpage/realsense/camera-sdk/v2016r3/documentation/html/index.html?doc_essential_record_and_playback_streams.html. Also, see sample source Rawstreams under the RSSDK\samples\core directory. The Rawstreams sample's record and playback capabilities work.

 

 

Hope this helps.

 

 

Regards,

 

-Yermi A.

 

0 Kudos
idata
Employee
459 Views

Hi Praveen,

 

 

I would like to know if you still need help in this case.

 

 

Regards,

 

-Yermi A.

 

0 Kudos
PKuma35
Beginner
459 Views
0 Kudos
idata
Employee
459 Views

Hi Praveen,

 

 

Thanks for your reply. Did you try to run the recording and playing back SDK example as well as the Rawstreams under RSSDK\sample\core directory? I would like to know if they work for you.

 

 

Regards,

 

-Yermi A.
0 Kudos
PKuma35
Beginner
459 Views

Hi Yermi,

Thanks for your information. Yes, those sample codes work. However, in my code snippet, there is a problem with the GetFileName function in particular.

 

Can you help me figure that as per the initial question?

YermiA_Intel

0 Kudos
idata
Employee
459 Views

Hi Praveen,

 

 

I'd recommend to use those examples as reference in your code, however, let me try to investigate a little bit more about your issue.

 

 

I'll appreciate your patience during the meantime.

 

 

Regards,

 

-Yermi A

 

0 Kudos
PKuma35
Beginner
459 Views

Hi YermiA_Intel intel_corp

 

thanks for your reply.

I was trying to execute one small piece of code below:-

However I got an error which is given as follows:-

An unhandled exception of type 'System.DllNotFoundException' occurred in Intel.RealSense.cs.dll

Additional information: Unable to load DLL 'libpxccore_c': The specified module could not be found. (Exception from HRESULT: 0x8007007E)

The code that I tried to execute is given below:-

namespace Real_Sense_Recording_test

{

class Program

{

static void Main()

{

string filelocation = "C:\\Users\\310278044\\Desktop\\Scans";

SenseManager sm = SenseManager.CreateInstance();

CaptureManager cm = sm.CaptureManager;

cm.SetFileName(filelocation, true);

SampleReader reader = SampleReader.Activate(sm);

reader.EnableStream(StreamType.STREAM_TYPE_COLOR, 640, 480, 30);

sm.Init();

for (int i = 0; i < 300; i++)

{

//cm.FrameIndex = i;

//sm.FlushFrame();

if (sm.AcquireFrame(true).IsError())

break;

//Status sts = sm.AcquireFrame(true);

//if (sts < Status::STATUS_NO_ERROR)

// break;

Sample sample = reader.Sample;

sm.ReleaseFrame();

}

sm.Dispose();

}

}

}

I did get the error right in the first line itself(Sensemanager initiation).

0 Kudos
idata
Employee
459 Views

Hi Praveen,

 

 

I was running the RawStreams.cpp sample that uses the SetFileName function, I was able to record a file, the my_gui.cpp code uses that function, and I'd suggest to look at that code and use it as a reference to yours.

 

 

Moreover, I was looking at the Camera_viewer.cpp sample that uses SenseManager interface, it works in the sample, and you may run this one too to know if you still get that error, additionally, you can use an if sentence to know if you are able to create the SenseManager as it is used in the sample.

 

 

I'll take a look at the error you are getting, I have made my tests using the SDK R3 and I would like to know if you are using this one too.

 

 

Normally in these cases with custom codes we bring the tools or tips to help the user to develop his own code because it is beyond our scope of support.

 

 

Regards,

 

-Yermi A.

 

0 Kudos
PKuma35
Beginner
459 Views

Hi YermiA_Intel intel_corp @Intel

Thanks for your reply. A quick question. I am able to initialize the session using the following snippet:

PXCMSenseManager pp = PXCMSenseManager.CreateInstance();

PXCMCaptureManager cm = pp.captureManager;

However, when I try to initiate a session using the new SDK documentation (2016 R3), I get an exception saying "System.DLLNotFoundException" in Intel.RealSense.cs.dll. Please find the snippet as per new documentation below:-

Intel.RealSense.SenseManager pp = Intel.RealSense.SenseManager.CreateInstance();

CaptureManager cm = pp.CaptureManager;

Let me know if I am missing something.

 

Thanks again.
0 Kudos
idata
Employee
459 Views

Hi Praveen,

 

 

This seems like a development environment configuration issue. Please ensure that libpxccore_c.dll exists under c:\program files (x86)\Intel\RSSDK\runtime\core\Win32 and x64. If it doesn't, I recommend you to reinstall the SDK 2016 R3. You can look at the sample RSSDK\sample\core\Rawstreams.cs\ for a proper solution configuration.

 

 

Hope this information helps.

 

 

Regards,

 

-Yermi A.

 

0 Kudos
Reply