title: Get pixel color from ByteArray
body: <p>I have an image with size 160x175 pixels. I loaded it in a byte array with this code:</p>
  
  <pre><code>var file = await StorageFile.GetFileFromApplicationUriAsync(
      new Uri("ms-appx:///Assets/Image.png"));
  
  using (var stream = await file.OpenAsync(FileAccessMode.Read))
  {
      var decoder = await BitmapDecoder.CreateAsync(stream);
  
      var myTransform = new BitmapTransform
      {
          ScaledHeight = (uint)pixelHeight,
          ScaledWidth = (uint)pixelWidth
      };
  
      var pixels = await decoder.GetPixelDataAsync(
          BitmapPixelFormat.Rgba8,
          BitmapAlphaMode.Straight,
          myTransform,
          ExifOrientationMode.IgnoreExifOrientation,
          ColorManagementMode.DoNotColorManage);
  
      var bytes = pixels.DetachPixelData();
  }
  </code></pre>
  
  <p>Now I want to check each pixel if its transparency or not. My byte array has a length of 112000. I think 160px * 175px * 4 (RGBA). So is it right if every 4th byte in the byte array is the transparency byte of the pixel, and when its content is 255 it's transparency?</p>
  
  <p>And how the pixels are sorted in the byte array? Horizontal or vertical?</p>
  
  <p>I can't find anything in MSDN about what a byte array with pixels looks like.</p>