ByteScout PDF Suite - C# - Convert pdf to 1-bit bmp with pdf renderer sdk - ByteScout

ByteScout PDF Suite – C# – Convert pdf to 1-bit bmp with pdf renderer sdk

  • Home
  • /
  • Articles
  • /
  • ByteScout PDF Suite – C# – Convert pdf to 1-bit bmp with pdf renderer sdk

How to convert pdf to 1 bit bmp with pdf renderer sdk in C# and ByteScout PDF Suite

Learning is essential in computer world and the tutorial below will demonstrate how to convert pdf to 1 bit bmp with pdf renderer sdk in C#

Source code documentation samples give simple and easy method to install a needed feature into your application. ByteScout PDF Suite can convert pdf to 1 bit bmp with pdf renderer sdk. It can be applied from C#. ByteScout PDF Suite is the bundle that provides six different SDK libraries to work with PDF from generating rich PDF reports to extracting data from PDF documents and converting them to HTML. This bundle includes PDF (Generator) SDK, PDF Renderer SDK, PDF Extractor SDK, PDF to HTML SDK, PDF Viewer SDK and PDF Generator SDK for Javascript.

Want to quickly learn? This fast application programming interfaces of ByteScout PDF Suite for C# plus the guidelines and the code below will help you quickly learn how to convert pdf to 1 bit bmp with pdf renderer sdk. Simply copy and paste in your C# project or application you and then run your app! Want to see how it works with your data then code testing will allow the function to be tested and work properly.

If you want to try other source code samples then the free trial version of ByteScout PDF Suite is available for download from our website. Just try other source code samples for C#.

On-demand (REST Web API) version:
 Web API (on-demand version)

On-premise offline SDK for Windows:
 60 Day Free Trial (on-premise)

Program.cs
      
using System.Drawing; using System.Drawing.Imaging; using System.Diagnostics; using Bytescout.PDFRenderer; namespace PDF2BMP { class Program { static void Main(string[] args) { // Create an instance of Bytescout.PDFRenderer.RasterRenderer object and register it. RasterRenderer renderer = new RasterRenderer(); renderer.RegistrationName = "demo"; renderer.RegistrationKey = "demo"; // Load PDF document. renderer.LoadDocumentFromFile("multipage.pdf"); RenderingOptions renderingOptions = new RenderingOptions(); // Set pixel format to 1-bit renderingOptions.ImageBitsPerPixel = ImageBitsPerPixel.BPP1; for (int i = 0; i < renderer.GetPageCount(); i++) { // Save 1-bit image to file renderer.Save("image" + i + ".bmp", RasterImageFormat.BMP, i, 200, renderingOptions); } // Cleanup renderer.Dispose(); // Open result document in default associated application (for demo purpose) ProcessStartInfo processStartInfo = new ProcessStartInfo("image0.bmp"); processStartInfo.UseShellExecute = true; Process.Start(processStartInfo); } } }

ON-PREMISE OFFLINE SDK

60 Day Free Trial or Visit ByteScout PDF Suite Home Page

Explore ByteScout PDF Suite Documentation

Explore Samples

Sign Up for ByteScout PDF Suite Online Training

ON-DEMAND REST WEB API

Get Your API Key

Explore Web API Docs

Explore Web API Samples

VIDEO

ON-PREMISE OFFLINE SDK

60 Day Free Trial or Visit ByteScout PDF Suite Home Page

Explore ByteScout PDF Suite Documentation

Explore Samples

Sign Up for ByteScout PDF Suite Online Training

ON-DEMAND REST WEB API

Get Your API Key

Explore Web API Docs

Explore Web API Samples

Tutorials:

prev
next