예제 #1
0
        static void Main(string[] args)
        {
            Console.WriteLine("Render pages...");
            pRender = new PageRenderer();
            ////pRender.OnPDFLoaded += PRender_OnPDFLoaded;
            Console.WriteLine("Loading PDF");
            pRender.LoadPDF("compressed.tracemonkey-pldi-09.pdf");
            Console.WriteLine("Getting page images...");
            for (int i = 0; i < pRender.PageCount; i++)
            {
                pRender.RenderPage(i, 1280, 1280).Save("capture_" + (i + 1) + ".png");
            }

            AddImageToPDF("maxresdefault.jpg");

            Console.WriteLine("Done.");
        }