/// <summary> /// Construct a group from a set of image capabilities for your device /// </summary> /// <param name="width">The width of the device</param> /// <param name="height">The height of the device</param> /// <param name="depth">The depth of the device</param> /// <param name="fmt">The format of the device</param> public Group(int width, int height, int depth, System.Drawing.Imaging.ImageFormat fmt) { byte[] data = new byte[16]; data[0] = 0x0A; data[1] = 0x01; BitConverter.GetBytes((short)depth.GetHashCode()).CopyTo(data, 2); BitConverter.GetBytes(width.GetHashCode()).CopyTo(data, 4); BitConverter.GetBytes(height.GetHashCode()).CopyTo(data, 8); BitConverter.GetBytes(fmt.GetHashCode()).CopyTo(data, 12); this.m_id = new Guid(data); this.m_friendlyName = fmt.ToString() + " W:" + width + " H:" + height + " D:" + depth; }