<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>MuPDF on SoloSoft</title><link>https://www.solosoft.dev/tags/mupdf/</link><description>Recent content in MuPDF on SoloSoft</description><generator>Hugo</generator><language>en-us</language><lastBuildDate>Fri, 01 May 2026 00:00:00 +0000</lastBuildDate><atom:link href="https://www.solosoft.dev/tags/mupdf/index.xml" rel="self" type="application/rss+xml"/><item><title>PyMuPDF: High-Performance PDF Processing for Python</title><link>https://www.solosoft.dev/post/pymupdf-pdf-2026/</link><pubDate>Fri, 01 May 2026 00:00:00 +0000</pubDate><guid>https://www.solosoft.dev/post/pymupdf-pdf-2026/</guid><description>&lt;p&gt;When you need raw speed for PDF processing, PyMuPDF is the performance leader among Python PDF libraries. Built as a Python binding to the C-based MuPDF library from Artifex, PyMuPDF combines Python&amp;rsquo;s ease of use with C-level performance for rendering, extracting, and manipulating PDF documents.&lt;/p&gt;
&lt;p&gt;PyMuPDF processes PDFs 10-100x faster than pure Python alternatives. It renders pages to images in milliseconds, extracts text with precise positioning, manages annotations, and handles forms. Beyond PDF, it also supports XPS, EPUB, MOBI, FB2, and common image formats, making it a versatile document processing engine.&lt;/p&gt;
&lt;h2 id="performance-benchmarks"&gt;Performance Benchmarks&lt;/h2&gt;
&lt;table&gt;
 &lt;thead&gt;
 &lt;tr&gt;
 &lt;th&gt;Operation&lt;/th&gt;
 &lt;th&gt;PyMuPDF&lt;/th&gt;
 &lt;th&gt;pypdf&lt;/th&gt;
 &lt;th&gt;pdfminer&lt;/th&gt;
 &lt;th&gt;Units&lt;/th&gt;
 &lt;/tr&gt;
 &lt;/thead&gt;
 &lt;tbody&gt;
 &lt;tr&gt;
 &lt;td&gt;Text extraction (100 pages)&lt;/td&gt;
 &lt;td&gt;0.3&lt;/td&gt;
 &lt;td&gt;4.2&lt;/td&gt;
 &lt;td&gt;8.5&lt;/td&gt;
 &lt;td&gt;seconds&lt;/td&gt;
 &lt;/tr&gt;
 &lt;tr&gt;
 &lt;td&gt;Page rendering&lt;/td&gt;
 &lt;td&gt;0.05&lt;/td&gt;
 &lt;td&gt;N/A&lt;/td&gt;
 &lt;td&gt;N/A&lt;/td&gt;
 &lt;td&gt;seconds per page&lt;/td&gt;
 &lt;/tr&gt;
 &lt;tr&gt;
 &lt;td&gt;Memory usage&lt;/td&gt;
 &lt;td&gt;45&lt;/td&gt;
 &lt;td&gt;120&lt;/td&gt;
 &lt;td&gt;200&lt;/td&gt;
 &lt;td&gt;MB for 1000 pages&lt;/td&gt;
 &lt;/tr&gt;
 &lt;tr&gt;
 &lt;td&gt;PDF merge (50 files)&lt;/td&gt;
 &lt;td&gt;0.8&lt;/td&gt;
 &lt;td&gt;2.1&lt;/td&gt;
 &lt;td&gt;N/A&lt;/td&gt;
 &lt;td&gt;seconds&lt;/td&gt;
 &lt;/tr&gt;
 &lt;/tbody&gt;
&lt;/table&gt;
&lt;h2 id="core-capabilities"&gt;Core Capabilities&lt;/h2&gt;
&lt;table&gt;
 &lt;thead&gt;
 &lt;tr&gt;
 &lt;th&gt;Feature&lt;/th&gt;
 &lt;th&gt;Description&lt;/th&gt;
 &lt;/tr&gt;
 &lt;/thead&gt;
 &lt;tbody&gt;
 &lt;tr&gt;
 &lt;td&gt;Page rendering&lt;/td&gt;
 &lt;td&gt;Convert pages to PNG, JPEG, or Pixmap at any resolution&lt;/td&gt;
 &lt;/tr&gt;
 &lt;tr&gt;
 &lt;td&gt;Text extraction&lt;/td&gt;
 &lt;td&gt;Get text with positions, fonts, and styles&lt;/td&gt;
 &lt;/tr&gt;
 &lt;tr&gt;
 &lt;td&gt;Image extraction&lt;/td&gt;
 &lt;td&gt;Extract embedded images in original format&lt;/td&gt;
 &lt;/tr&gt;
 &lt;tr&gt;
 &lt;td&gt;Annotation management&lt;/td&gt;
 &lt;td&gt;Add, edit, and remove highlights, notes, stamps&lt;/td&gt;
 &lt;/tr&gt;
 &lt;tr&gt;
 &lt;td&gt;Document conversion&lt;/td&gt;
 &lt;td&gt;Convert between PDF, XPS, EPUB, and images&lt;/td&gt;
 &lt;/tr&gt;
 &lt;/tbody&gt;
&lt;/table&gt;
&lt;h2 id="rendering-and-extraction-pipeline"&gt;Rendering and Extraction Pipeline&lt;/h2&gt;

&lt;figure class="mermaid-wrapper not-prose" role="img" aria-label="Mermaid diagram"&gt;
 &lt;div class="mermaid-container"&gt;
 &lt;pre class="mermaid"&gt;flowchart LR
 A[PDF/XPS/EPUB] --&amp;gt; B[MuPDF Core Engine]
 B --&amp;gt; C{Operation}
 C --&amp;gt;|Render| D[Page Pixmap]
 D --&amp;gt; E[Image Output]
 C --&amp;gt;|Extract| F[Text Dictionary]
 F --&amp;gt; G[Structured Text]
 C --&amp;gt;|Annotate| H[Annotation Objects]
 H --&amp;gt; I[Modified Page]
 C --&amp;gt;|Transform| J[Rotate/Scale/Clip]
 J --&amp;gt; I
 I --&amp;gt; K[Save PDF]&lt;/pre&gt;
 &lt;script type="application/mermaid"&gt;flowchart LR
 A[PDF/XPS/EPUB] --&gt; B[MuPDF Core Engine]
 B --&gt; C{Operation}
 C --&gt;|Render| D[Page Pixmap]
 D --&gt; E[Image Output]
 C --&gt;|Extract| F[Text Dictionary]
 F --&gt; G[Structured Text]
 C --&gt;|Annotate| H[Annotation Objects]
 H --&gt; I[Modified Page]
 C --&gt;|Transform| J[Rotate/Scale/Clip]
 J --&gt; I
 I --&gt; K[Save PDF]&lt;/script&gt;
 &lt;/div&gt;
&lt;/figure&gt;&lt;p&gt;The MuPDF core engine parses the document structure and provides high-speed access to every element. Python bindings wrap this into familiar objects like &lt;code&gt;Document&lt;/code&gt;, &lt;code&gt;Page&lt;/code&gt;, and &lt;code&gt;Pixmap&lt;/code&gt; with intuitive methods.&lt;/p&gt;</description></item></channel></rss>