Beispiel #1
0
        public virtual void GetSourceGeometry(
            out ID2D1Geometry sourceGeometry
            )
        {
            var fp = GetFunctionPointer(17);

            if (m_GetSourceGeometryFunc == null)
            {
                m_GetSourceGeometryFunc = (GetSourceGeometryFunc)Marshal.GetDelegateForFunctionPointer(fp, typeof(GetSourceGeometryFunc));
            }
            sourceGeometry = new ID2D1Geometry();
            m_GetSourceGeometryFunc(m_ptr, out sourceGeometry.PtrForNew);
        }
Beispiel #2
0
        public virtual void GetSourceGeometries(
            out ID2D1Geometry geometries,
            uint geometriesCount
            )
        {
            var fp = GetFunctionPointer(19);

            if (m_GetSourceGeometriesFunc == null)
            {
                m_GetSourceGeometriesFunc = (GetSourceGeometriesFunc)Marshal.GetDelegateForFunctionPointer(fp, typeof(GetSourceGeometriesFunc));
            }
            geometries = new ID2D1Geometry();
            m_GetSourceGeometriesFunc(m_ptr, out geometries.PtrForNew, geometriesCount);
        }
Beispiel #3
0
        public virtual void FillGeometry(
            ID2D1Geometry geometry,
            ID2D1Brush brush,
            ID2D1Brush opacityBrush
            )
        {
            var fp = GetFunctionPointer(23);

            if (m_FillGeometryFunc == null)
            {
                m_FillGeometryFunc = (FillGeometryFunc)Marshal.GetDelegateForFunctionPointer(fp, typeof(FillGeometryFunc));
            }

            m_FillGeometryFunc(m_ptr, geometry != null ? geometry.Ptr : IntPtr.Zero, brush != null ? brush.Ptr : IntPtr.Zero, opacityBrush != null ? opacityBrush.Ptr : IntPtr.Zero);
        }
Beispiel #4
0
        public virtual int CreateTransformedGeometry(
            ID2D1Geometry sourceGeometry,
            ref System.Numerics.Matrix3x2 transform,
            out ID2D1TransformedGeometry transformedGeometry
            )
        {
            var fp = GetFunctionPointer(9);

            if (m_CreateTransformedGeometryFunc == null)
            {
                m_CreateTransformedGeometryFunc = (CreateTransformedGeometryFunc)Marshal.GetDelegateForFunctionPointer(fp, typeof(CreateTransformedGeometryFunc));
            }
            transformedGeometry = new ID2D1TransformedGeometry();
            return(m_CreateTransformedGeometryFunc(m_ptr, sourceGeometry != null ? sourceGeometry.Ptr : IntPtr.Zero, ref transform, out transformedGeometry.PtrForNew));
        }
Beispiel #5
0
        public virtual int CompareWithGeometry(
            ID2D1Geometry inputGeometry,
            ref System.Numerics.Matrix3x2 inputGeometryTransform,
            float flatteningTolerance,
            out D2D1_GEOMETRY_RELATION relation
            )
        {
            var fp = GetFunctionPointer(8);

            if (m_CompareWithGeometryFunc == null)
            {
                m_CompareWithGeometryFunc = (CompareWithGeometryFunc)Marshal.GetDelegateForFunctionPointer(fp, typeof(CompareWithGeometryFunc));
            }

            return(m_CompareWithGeometryFunc(m_ptr, inputGeometry != null ? inputGeometry.Ptr : IntPtr.Zero, ref inputGeometryTransform, flatteningTolerance, out relation));
        }
Beispiel #6
0
        public virtual void DrawGeometry(
            ID2D1Geometry geometry,
            ID2D1Brush brush,
            float strokeWidth,
            ID2D1StrokeStyle strokeStyle
            )
        {
            var fp = GetFunctionPointer(22);

            if (m_DrawGeometryFunc == null)
            {
                m_DrawGeometryFunc = (DrawGeometryFunc)Marshal.GetDelegateForFunctionPointer(fp, typeof(DrawGeometryFunc));
            }

            m_DrawGeometryFunc(m_ptr, geometry != null ? geometry.Ptr : IntPtr.Zero, brush != null ? brush.Ptr : IntPtr.Zero, strokeWidth, strokeStyle != null ? strokeStyle.Ptr : IntPtr.Zero);
        }
Beispiel #7
0
        public virtual int CreateGeometryGroup(
            D2D1_FILL_MODE fillMode,
            out ID2D1Geometry geometries,
            uint geometriesCount,
            out ID2D1GeometryGroup geometryGroup
            )
        {
            var fp = GetFunctionPointer(8);

            if (m_CreateGeometryGroupFunc == null)
            {
                m_CreateGeometryGroupFunc = (CreateGeometryGroupFunc)Marshal.GetDelegateForFunctionPointer(fp, typeof(CreateGeometryGroupFunc));
            }
            geometries = new ID2D1Geometry(); geometryGroup = new ID2D1GeometryGroup();
            return(m_CreateGeometryGroupFunc(m_ptr, fillMode, out geometries.PtrForNew, geometriesCount, out geometryGroup.PtrForNew));
        }
Beispiel #8
0
        public virtual int CombineWithGeometry(
            ID2D1Geometry inputGeometry,
            D2D1_COMBINE_MODE combineMode,
            ref System.Numerics.Matrix3x2 inputGeometryTransform,
            float flatteningTolerance,
            ID2D1SimplifiedGeometrySink geometrySink
            )
        {
            var fp = GetFunctionPointer(11);

            if (m_CombineWithGeometryFunc == null)
            {
                m_CombineWithGeometryFunc = (CombineWithGeometryFunc)Marshal.GetDelegateForFunctionPointer(fp, typeof(CombineWithGeometryFunc));
            }

            return(m_CombineWithGeometryFunc(m_ptr, inputGeometry != null ? inputGeometry.Ptr : IntPtr.Zero, combineMode, ref inputGeometryTransform, flatteningTolerance, geometrySink != null ? geometrySink.Ptr : IntPtr.Zero));
        }