Skip to content

Resolution 896X504 not working on hololens 2 #6

Description

@LydiaYounsi

Hello,

I’m working with the HololensCameraStream in my project. Until now, I was working with 2272x1278 resolution without any issues. However, after reducing the resolution to 896x504, the output image becomes corrupted:

image

Below is the code snippet where I configure the camera resolution:

_resolution = CameraStreamHelper.Instance.GetLowestResolution();
float frameRate = CameraStreamHelper.Instance.GetLowestFrameRate(_resolution);
video.FrameSampleAcquired += OnFrameSampleAcquired;
CameraParameters cameraParameters = new CameraParameters();
cameraParameters.hologramOpacity = 0.0f;
cameraParameters.frameRate = Mathf.RoundToInt(frameRate);
cameraParameters.cameraResolutionWidth = _resolution.width;
cameraParameters.cameraResolutionHeight = _resolution.height;
cameraParameters.pixelFormat = CapturePixelFormat.BGRA32;
video.StartVideoModeAsync(cameraParameters, OnStartedVideoCaptureMode);

Do you have any insights on what might be causing this image corruption when changing resolutions?

Thank you in advance for your support

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions