PHPackages                             moroz1999/sxg - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. moroz1999/sxg

ActivePackage[Utility &amp; Helpers](/categories/utility)

moroz1999/sxg
=============

SXG conversion/generation in PHP

1.0.4(1y ago)354CC0-1.0PHPPHP &gt;=5.6.0

Since Mar 27Pushed 1y ago3 watchersCompare

[ Source](https://github.com/moroz1999/sxg)[ Packagist](https://packagist.org/packages/moroz1999/sxg)[ Docs](https://github.com/moroz1999/sxg)[ RSS](/packages/moroz1999-sxg/feed)WikiDiscussions master Synced 3w ago

READMEChangelogDependenciesVersions (9)Used By (0)

SXG
===

[](#sxg)

This repository contains the tools required for SXG images generation in PHP.

Usage example
-------------

[](#usage-example)

```
$gd = imagecreatefromjpeg('boobs.jpg');

include_once('src/Sxg/Image.php');
$image = new Sxg\Image();
$image->setWidth(320);
$image->setHeight(240);
$array = [
    0x000fff,
    0xff00ff,
    0x000000,
    0xff0000,
    0xffff00,
    0xffffff,
    0xf0ff30,
    0x808080,
    0x80f080,
    0xcdcdcd,
    0xf7cdb4,
    0x432118,
    0xb58169,
];
$image->setColorFormat($image::SXG_COLOR_FORMAT_16);
$image->setRgbPalette($array);
$image->setPaletteType($image::SXG_PALETTE_FORMAT_CLUT);
$image->importFromGd($gd);
file_put_contents('test.sxg', $image->getSxgData());
```

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

[](#installation)

Composer

```
{
    "require": {
		"moroz1999/sxg": "*"
    }
}
```

Links
-----

[](#links)

- ["SXG Format description"](http://forum.tslabs.info/viewtopic.php?f=25&t=526) - *in Russian*
- ["Video modes and architecture of TS-Config on ZX Evolution"](http://forum.tslabs.info/viewtopic.php?f=35&t=178) - *in Russian*

License
-------

[](#license)

Creative Commons Zero v1.0 Universal

###  Health Score

33

—

LowBetter than 72% of packages

Maintenance36

Infrequent updates — may be unmaintained

Popularity12

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity63

Established project with proven stability

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~451 days

Recently: every ~789 days

Total

8

Last Release

590d ago

Major Versions

0.0.3 → 1.0.02016-03-27

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/11526203?v=4)[moroz1999](/maintainers/moroz1999)[@moroz1999](https://github.com/moroz1999)

---

Top Contributors

[![moroz1999](https://avatars.githubusercontent.com/u/11526203?v=4)](https://github.com/moroz1999 "moroz1999 (2 commits)")

---

Tags

phpzx spectrumzx evolutionsxg

### Embed Badge

![Health badge](/badges/moroz1999-sxg/health.svg)

```
[![Health](https://phpackages.com/badges/moroz1999-sxg/health.svg)](https://phpackages.com/packages/moroz1999-sxg)
```

###  Alternatives

[imanghafoori/laravel-anypass

A minimal yet powerful package to help you in development.

21422.6k](/packages/imanghafoori-laravel-anypass)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
