PHPackages                             tecnickcom/tc-lib-pdf-graph - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [PDF &amp; Document Generation](/categories/documents)
4. /
5. tecnickcom/tc-lib-pdf-graph

ActiveLibrary[PDF &amp; Document Generation](/categories/documents)

tecnickcom/tc-lib-pdf-graph
===========================

PHP library containing PDF graphic and geometric methods

2.14.1(1w ago)5719.9k↓16.4%41LGPL-3.0-or-laterPHPPHP &gt;=8.2CI passing

Since Dec 14Pushed 1w ago1 watchersCompare

[ Source](https://github.com/tecnickcom/tc-lib-pdf-graph)[ Packagist](https://packagist.org/packages/tecnickcom/tc-lib-pdf-graph)[ Docs](https://tcpdf.org)[ GitHub Sponsors](https://github.com/sponsors/tecnickcom)[ RSS](/packages/tecnickcom-tc-lib-pdf-graph/feed)WikiDiscussions main Synced 2d ago

READMEChangelogDependencies (16)Versions (114)Used By (1)

tc-lib-pdf-graph
================

[](#tc-lib-pdf-graph)

> Geometric drawing and transformation primitives for PDF content streams.

[![Latest Stable Version](https://camo.githubusercontent.com/4cf93bcde20e86692af2a085f132365be0a22ecbd0feefe5560885d4d3636667/68747470733a2f2f706f7365722e707567782e6f72672f7465636e69636b636f6d2f74632d6c69622d7064662d67726170682f76657273696f6e)](https://packagist.org/packages/tecnickcom/tc-lib-pdf-graph)[![Build](https://github.com/tecnickcom/tc-lib-pdf-graph/actions/workflows/check.yml/badge.svg)](https://github.com/tecnickcom/tc-lib-pdf-graph/actions/workflows/check.yml)[![Coverage](https://camo.githubusercontent.com/a005d9308bdadcf9941b2195df7ae06332ce41448bf79c1e704ce5bb657fa08c/68747470733a2f2f636f6465636f762e696f2f67682f7465636e69636b636f6d2f74632d6c69622d7064662d67726170682f67726170682f62616467652e7376673f746f6b656e3d4c717866776850423847)](https://codecov.io/gh/tecnickcom/tc-lib-pdf-graph)[![License](https://camo.githubusercontent.com/f8e9981274d69726616e682bf6cd35bf373567840fabac646e282f46b8beceea/68747470733a2f2f706f7365722e707567782e6f72672f7465636e69636b636f6d2f74632d6c69622d7064662d67726170682f6c6963656e7365)](https://packagist.org/packages/tecnickcom/tc-lib-pdf-graph)[![Downloads](https://camo.githubusercontent.com/b0f73f5c1746a166812f56fbf5600512137eb2d416e1ed04d8904bdc0d03470c/68747470733a2f2f706f7365722e707567782e6f72672f7465636e69636b636f6d2f74632d6c69622d7064662d67726170682f646f776e6c6f616473)](https://packagist.org/packages/tecnickcom/tc-lib-pdf-graph)

[![Sponsor on GitHub](https://camo.githubusercontent.com/dd89cb32d6e7ff9dbb0fa7ce84923567358b220feb9198b3720beabc3153da6a/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f73706f6e736f722d6769746875622d4541344141412e7376673f6c6f676f3d67697468756273706f6e736f7273266c6f676f436f6c6f723d7768697465)](https://github.com/sponsors/tecnickcom)

> 💖 Part of the [tc-lib-pdf / TCPDF](https://github.com/tecnickcom/tc-lib-pdf) ecosystem (100M+ installs). [Sponsor its maintenance →](https://github.com/sponsors/tecnickcom)

---

Overview
--------

[](#overview)

`tc-lib-pdf-graph` implements low-level drawing operations used to build PDF graphic content.

It exposes the primitives needed to compose paths and painting operations while keeping the API close to PDF graphics operators. This makes it suitable as a foundation layer for charting, vector drawing, and custom layout engines.

**Namespace**`\Com\Tecnick\Pdf\Graph`**Author**Nicola Asuni **License**[GNU LGPL v3](https://www.gnu.org/copyleft/lesser.html) - see [LICENSE](LICENSE)**API docs****Packagist**---

Features
--------

[](#features)

### Drawing Primitives

[](#drawing-primitives)

- Paths, lines, curves, and clipping operations
- Style handling for stroke/fill combinations
- Gradient and shading support

### Transformations

[](#transformations)

- Matrix-based geometric transforms
- Coordinate conversion helpers
- PDF/A-aware behavior controls

---

Requirements
------------

[](#requirements)

- PHP 8.2 or later
- Extension: `zlib`
- Composer

---

Installation
------------

[](#installation)

```
composer require tecnickcom/tc-lib-pdf-graph
```

---

Quick Start
-----------

[](#quick-start)

```
