Download the PHP package iliaal/fastchart without Composer

On this page you can find all versions of the php package iliaal/fastchart. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package fastchart

fastchart

Tests Version License: BSD-3-Clause Follow @iliaa

Native C PHP extension. 19 chart types behind a modern OO API with fluent setters and final classes. Line, area, bar, scatter, bubble, pie, radar, polar, surface, contour, gauge, gantt, box-plot, treemap, funnel, waterfall, heatmap, linear meter, plus a deep StockChart (seven candle styles, SMA / EMA / WMA overlays, volume + indicator panes).

Two render paths. renderToFile() / renderPng() / renderJpeg() / renderWebp() / renderAvif() cover the common case: declare a chart, get a file or bytes back. draw($canvas) is the other path. Hand fastchart a \GdImage you own and it returns the same canvas, so you can composite several charts onto one image, stamp arbitrary ext/gd draw calls over the result, or drop the rendered chart into a larger image pipeline (PDF page, sprite sheet, dashboard tile).

Status

Working. 19 chart types, 105 public methods, 97 phpt tests. The OO surface is stable for the v0.1 line. See CHANGELOG.md for what's shipped.

Install

Build from source against the PHP install you want to extend:

Strict-warnings dev build (recommended for contributors):

Runtime check:

Requirements

Quick start

The shortest path is the renderToFile() helper, which picks the encoder from the file extension:

renderPng(), renderJpeg(), renderWebp(), and renderAvif() return the encoded bytes if you need them in memory.

For pixel-level control or compositing several charts on one image, hand fastchart a \GdImage you own. draw() returns the same canvas back so call chains keep working:

📊 Performance

Median in-memory renderPng() time on a single core (Intel i9-13950HX, PHP 8.4 NTS, default font + DPI). Same data shape per chart type at both resolutions, alphabetical by class name.

Chart 640×480 ms 1920×1080 ms 1080p ops/sec
AreaChart 24 76 13
BarChart 39 84 12
BoxPlot 16 60 17
BubbleChart 13 62 16
ContourChart 9 52 19
Funnel 14 52 19
GanttChart 18 61 16
GaugeChart 10 60 17
Heatmap 9 56 18
LineChart 21 66 15
LinearMeter 9 50 20
PieChart 13 59 17
PolarChart 10 53 19
RadarChart 15 61 16
ScatterChart 17 60 17
StockChart 21 68 15
SurfaceChart 8 50 20
Treemap 18 60 17
Waterfall 18 61 16

Every chart type renders in under 100 ms at 1920×1080 on one thread. At dashboard-tile size (640×480), the lighter chart types break 100 renders per second per core.

Repro the numbers locally:

Iteration counts via FC_BENCH_SMALL_ITERS (default 200) and FC_BENCH_LARGE_ITERS (default 50). Bench source at docs/bench/bench.php.

What you can render

19 chart classes plus a 2-class symbology family, all under the FastChart\ namespace. Each name links to its rendered example image:

Cross-cutting features available on most chart types:

Examples

A gallery of code + rendered chart pairs lives in docs/README.md. Forty-two runnable scripts in docs/examples/ regenerate the images and exercise every public method on the API surface.

Public classes

All under the FastChart\ namespace:

Every setter returns static, so a single fluent expression configures and emits a chart. draw($canvas) returns the same \GdImage for the same reason.

The Symbol family lives parallel to Chart (no shared base — axes / palettes / plot rect have no meaning for a barcode):

🔗 PHP Performance Toolkit

Companion native PHP extensions for high-throughput PHP workloads:

License

BSD 3-Clause for the extension itself; see LICENSE. The vendored QR encoder under vendor/qrcodegen/ (nayuki/QR-Code-generator, C variant) is MIT — see vendor/qrcodegen/LICENSE. SPDX: (BSD-3-Clause AND MIT).


Follow @iliaa on XBlog • If this saved you a chart-rendering microservice, ⭐ star it!


All versions of fastchart with dependencies

PHP Build Version
Package Version
Requires php Version >=8.3
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package iliaal/fastchart contains the following files

Loading the files please wait ...