Relative Content

Tag Archive for c#drawing.net-standard

Converting an 24bppRGB memory to 32bppRGBx memory

I have an IntPtr pointing at a memory segment that stores pixel sequence in RGB888 format, so the length of this segment should be width * height * 3 bytes. I want to convert them to an byte array of pixels in RGB888x format, in other words, in a format every 4 elements in this array reprents a single pixel that the value of the last element doesn’t matter.