Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8067457
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 5, 20262026-06-05T12:18:08+00:00 2026-06-05T12:18:08+00:00

Maybe someone can help me. I need a Color32[] Array by calling GetPixels32(). Here

  • 0

Maybe someone can help me. I need a Color32[] Array by calling GetPixels32(). Here is a good solution for an QR-Code Reader with webcam.
How to decode QR code using Unity3D

Vuforia can unfortunately only give a byte array with…

Image.PIXEL_FORMAT mPixelFormat = Image.PIXEL_FORMAT.RGB565;
Image cameraImage = CameraDevice.Instance.GetCameraImage(mPixelFormat);
byte[] pixels = cameraImage.Pixels;

Does anyone have any idea how I can make a Pixel byte array to an Color32 array?
Here is my question in the Vuforia Forum.

Maybe anyone have any other solutions for QR-Code decoding in Unity for Android and iOS.
I would be very grateful for your help.

Edit: Here is the same Question in unityAnswers.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-05T12:18:11+00:00Added an answer on June 5, 2026 at 12:18 pm

    It looks like you’re requesting the image data in 16-bit R5G6B5 format, so I expect that’s what the data format is: pairs of bytes in 5-6-5-bit format. So, converting two bytes to a regular Color structure is something like:

    color.r = (byte[0] & 0x1f) / (float)(0x1f);
    color.g = ((byte[1] & 0x07) | ((byte[0] & 0xe0) >> 5)) / (float)(0x3f);
    color.b = ((byte[1] & 0xf8) >> 3) / (float)(0x1f);
    

    Then you can convert the Color to a Color32 just by casting it.

    This said, if you can request the image data in a 24-bit format instead of a 16-bit format then you can just feed the byte values directly to the channels of the Color32.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Hi maybe someone can help me here ... I have a slight problem with
Okay, the specs have changed on this one somewhat. Maybe someone can help me
Can someone maybe help me with this regex? I am using Javascript and classic
I'm having some trouble with xslt and was hoping that maybe someone here can
I can't figure out how to get the results I need. Can someone help?
I'm having trouble groking something in Linq - maybe someone can give me some
I'm a Linq noobie, maybe someone can point me in the right direction. What's
Can someone explain to me or maybe point a link or an example of
I thought I'd post here in the hope that maybe someone with MVVM expertise
It may be a bit too specific, but maybe someone here has experience extending

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.