public Sprite AddRGBA(byte[] src, Size size) { // Don't bother allocating empty sprites if (size.Width == 0 || size.Height == 0) { return(new Sprite(currentSheet, Rectangle.Empty, 0, float3.Zero, channel, BlendMode.Alpha)); } var rect = Allocate(size, 0, float3.Zero); Util.FastCopyIntoRGBA(rect, src); currentSheet.CommitBufferedData(); return(rect); }