Exemple #1
0
        public bool RenderPDFPageToBitmap(int pageNumber, IntPtr bitmapHandle, int dpiX, int dpiY, int boundsOriginX, int boundsOriginY, int boundsWidth, int boundsHeight, NativePdfiumMethods.FPDF flags)
        {
            if (_disposed)
            {
                throw new ObjectDisposedException(GetType().Name);
            }

            using (var pageData = new PageData(_document, _form, pageNumber))
            {
                NativePdfiumMethods.FPDF_RenderPageBitmap(bitmapHandle, pageData.Page, boundsOriginX, boundsOriginY, boundsWidth, boundsHeight, 0, flags);
            }

            return(true);
        }