/// <summary>
        /// Gets a reference to the singleton instance.
        /// </summary>
        public static SlimDXGraphicsDeviceService10 AddRef()
        {
            // Increment the "how many controls sharing the device" reference count.
            if (Interlocked.Increment(ref referenceCount) == 1)
            {
                // If this is the first control to start using the
                // device, we must create the singleton instance.
                singletonInstance = new SlimDXGraphicsDeviceService10();
            }

            return singletonInstance;
        }
        /// <summary>
        /// Gets a reference to the singleton instance.
        /// </summary>
        public static SlimDXGraphicsDeviceService10 AddRef()
        {
            // Increment the "how many controls sharing the device" reference count.
            if (Interlocked.Increment(ref referenceCount) == 1)
            {
                // If this is the first control to start using the
                // device, we must create the singleton instance.
                singletonInstance = new SlimDXGraphicsDeviceService10();
            }

            return(singletonInstance);
        }