private int XorImageIndex(BITMAPINFOHEADER bmInfoHeader) { RGBQUAD structure = new RGBQUAD(); return (Marshal.SizeOf(bmInfoHeader) + (this.dibNumColors(bmInfoHeader) * Marshal.SizeOf(structure))); }