microsoft / MixedReality-HolographicRemoting-Samples

Code samples for using Microsoft's Holographic Remoting library.
Other
141 stars 47 forks source link

player call MediaFrameReference.CoordinateSystem() Error #91

Closed ccrop closed 1 year ago

ccrop commented 1 year ago

Describe the bug use a custom built player After obtaining the localizable camera frame, obtaining the coordinates failed

To Reproduce Steps to reproduce the behavior:

  1. player on the HoloLens
  2. Connect from PC
  3. PC get some data Player side (e.g. your HoloLens 2) use a custom built player code: void VideoFrame::OnFrameArrived(const MediaFrameReader& sender, const MediaFrameArrivedEventArgs& args) { if (MediaFrameReference frame = sender.TryAcquireLatestFrame()) { std::lock_guard lock(m_frameMutex); auto coord = frame.CoordinateSystem(); //error m_latestFrame = frame; } } error: error code: frame.CoordinateSystem();
    0x00007FFA899EDF00 (KernelBase.dll)处(位于 SamplePlayer.exe 中)引发的异常: 0x40080202: WinRT transform error (参数: 0x0000000080040111, 0x0000000000000000, 0x0000000000000027, 0x000000E6808FAF50)。 0x00007FFA899EDF00 (KernelBase.dll)处(位于 SamplePlayer.exe 中)引发的异常: 0x40080202: WinRT transform error (参数: 0x0000000080040111, 0x0000000000000000, 0x0000000000000027, 0x000000E680EFE9F0)。 0x00007FFA899EDF00 (KernelBase.dll)处(位于 SamplePlayer.exe 中)引发的异常: 0x40080202: WinRT transform error (参数: 0x0000000080040111, 0x0000000000000000, 0x0000000000000027, 0x000000E6808FD4C0)。 0x00007FFA899EDF00 (KernelBase.dll)处(位于 SamplePlayer.exe 中)引发的异常: 0x40080202: WinRT transform error (参数: 0x0000000080040111, 0x0000000000000000, 0x0000000000000027, 0x000000E6808FCF60)。

Remote side (your Windows PC):

lappelsmeier commented 1 year ago

Hi @ccrop ,

am I correct in thinking that you try to get a pose for the PV camera? If so - these APIs are not wrapped at all by the remoting stack, so they are plain normal HoloLens OS APIs. If you see problems there it should have another cause (maybe a limited tracking mode or something similar?).

Once you get the coordinate system you can use the coordinate system synchronization (see https://learn.microsoft.com/en-us/windows/mixed-reality/develop/native/holographic-remoting-coordinate-system-synchronization-wmr) to get it into sync with the remote side.

I know from experience that we had other customers successfully getting the pose of the PV camera into a application on the remote side with the custom synchronization mentioned above.

lappelsmeier commented 1 year ago

Closing for now, let us know if you need more information.