31 Commits

Author SHA1 Message Date
Adrien Destugues
bb5da79264 CPC/SCR: allow 32K pictures.
Set R12 so that the picture can use the full video RAM, if it is large enough.


git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@2170 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2016-11-28 20:24:53 +00:00
Adrien Destugues
8808625851 Add a "tall 3" drawing mode.
Pixels with 3:4 aspect ratio. Why not?

Contributed by Nic Soudée (zoner/xylem). Thanks!


git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@2166 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2016-10-15 18:57:14 +00:00
Adrien Destugues
d3a4ced94c PPH loader fixes
- Fix palette computation, flickering two colors give a mix lighter than 50%
- Fix off by one error in B1 palette change decoding.


git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@2164 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2016-07-20 18:53:58 +00:00
Adrien Destugues
702f1835da Support loading PPH files (Amstrad CPC).
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@2162 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2016-07-19 20:28:43 +00:00
Adrien Destugues
3332b43330 Save and load support for GIMP palettes (.GPL files)
* Implemented by 00ai99
* Fixes https://code.google.com/p/grafx2/issues/detail?id=518


git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@2112 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2015-03-04 13:45:01 +00:00
Adrien Destugues
d9f2cd2d40 Remove no-op function Palette_loaded.
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@2109 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2015-03-04 09:28:23 +00:00
Adrien Destugues
5e26436c48 Fix mismatched parameters.
Bug caught by the Debian team on GrafX2 2.3.


git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@2072 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2014-05-16 10:15:07 +00:00
Yves Rizoud
cac2d00dfb Add support for saving/loading cycling colors in formats PI1 PC1. Also probably fix an error in PI1 footer (Issue 535)
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@2067 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2013-08-30 17:21:40 +00:00
Yves Rizoud
01543b7a8d Fix issue 535 : PC1 files created by Grafx2 can't be reloaded by Degas Elite
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@2063 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2013-08-29 22:08:22 +00:00
Adrien Destugues
92e438bde5 * Add codenet lua script (linux only for now) to send pictures to a runnning C64
* Fix C64 multicolor format :
   - Improve background color detection
   - Do not save as FLI unless the file extension matches

fixes #521, #522 and #524


git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@2043 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2012-12-29 18:58:07 +00:00
Yves Rizoud
56cdbc4c10 Issue 505: Support for saving IFF/ILBM format, compatible with Deluxe Paint 3
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@1993 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2012-09-15 18:05:44 +00:00
Yves Rizoud
a630a84822 Removed all usage of __attribute__((unused)), replaced by void cast which is supported both on GCC and VBCC
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@1984 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2012-08-11 16:19:07 +00:00
Adrien Destugues
86d67e4658 * Fix CPC palette for Mode 5 files : add 'undocumented' color codes
* Fix "layer support" detection, it didn't work for Mode 5.


git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@1966 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2012-06-24 18:03:21 +00:00
Adrien Destugues
b437d458d4 CPC Mode 5 fixes :
* Be case unsensitive when looking for the GFX-file,
 * When an underlay is hidden, do not use it and replace it with color 0, 1, 2 or 3. Allows to see pixel data 
alone or disable rasters on one color, as it's possible to get confused quite easily.


git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@1964 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2012-06-13 19:50:35 +00:00
Adrien Destugues
2aa9ea7f8e * Load Microsoft RIFF palette files
* Make byte, word, dword, qword typedefs instead of defines.


git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@1954 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2012-05-12 14:05:40 +00:00
Yves Rizoud
d8bb1e1d55 Fix some mostly harmless warnings and re-generated dependencies. Now compiles with zero warnings on Linux (gcc 4.1.2)
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@1945 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2012-05-03 21:32:59 +00:00
Yves Rizoud
55f4884e34 Fix a few compilation warnings on Linux; Fix a possible bug in Mode5 loader; Removed a pair of debug printfs in realpath.c
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@1933 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2012-03-14 19:17:35 +00:00
Yves Rizoud
d38f5ee981 CPC mode 5 : replaced the global Constraint_mode by a state (Image_mode) in each versioned T_Page: This allows keeping it sane when swapping to Spare, and when Undo/Redoing. Also fixed the first page when program starts, it was unnecessarily allocating pointers for the maximum number of layers(16)/frames(999)
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@1907 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2012-02-27 00:47:18 +00:00
Yves Rizoud
55d0889bc8 Change rendering system to use function pointers, see Issue 31 c38 : preliminary work to make the same executable handle Layers or Anims. Fixed an old issue where Lasso-ing a brush with right mouse button wouldn't erase cleanly (visual). Fixed an old issue where picking colors in layer 5 would not 'see' through layers.
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@1906 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2012-02-22 23:47:53 +00:00
Yves Rizoud
58e8194f40 Compilation fix for dependencies
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@1875 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2011-11-23 19:05:12 +00:00
Adrien Destugues
e875597964 Merge the "CPC Mode 5" branch to trunk.
Note this alsoincludes the "oldies" branch.

This has the following consequences :
[C64]
 * Loading and saving of screen-only, and color-only C64 picture is removed
 * Loading and saving in FLI mode is now possible
 * FLI constraint checker : tries to convert your image to FLI format, and put all the areas where it couldn't find a solution in a separate layer for you to fixup
 * This is currently accessible only with a shortcut. Menu will come next.
[Amstrad CPC]
 * Loading and saving of pictures in "Mode 5" is now possible. This custom format allows overscan mode 1 with rasters on 2 inks and split rasters on a 3rd one.
 * Mode 5 constraint enforcer : will ensure you can only draw pictures that are valid in mode 5. Each ink is seen as a layer.
 * This is accessible from a new button in the FX menu.
[Generic]
 * Added patch as I saw it : platform that don't support reporting "free space" on disk will not display anything (instead of "0 bytesÃ" as before)
 * For other platforms, when the free space is 0, we now have a disk full message.

The merge was not straight forward. I hope I didn't break too much things.


git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@1810 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2011-06-19 20:15:22 +00:00
Yves Rizoud
55422d160e (mode5 branch) Fix a bug in saving, including autosave every few minutes, that auto-selects the last layer to draw.
git-svn-id: svn://pulkomandy.tk/GrafX2/branches/cpcmode5@1743 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2011-03-02 22:07:24 +00:00
Adrien Destugues
cd8f3e40da * Save CM5 files. There seem to be a problem with "Supports_layers" field. setting it to 1 still triggers the warning that image will be flatenned...
git-svn-id: svn://pulkomandy.tk/GrafX2/branches/cpcmode5@1724 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2011-02-15 19:34:36 +00:00
Adrien Destugues
bf9c34d7fe Code for loading "CM5" (CPC Mode 5) pixtures
* Fix a bug in the Set_layer function : it was only possible to set a new layer, and this format needs us to write to previous layers too
 * Saving is missing (you need to save as png then convert back to cm5 using SyX converter)
 * Preview does not work (it does not use layers, so the result is broken)
 * Loading switches the "8bit" mode on automatically

git-svn-id: svn://pulkomandy.tk/GrafX2/branches/cpcmode5@1723 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2011-02-15 17:48:16 +00:00
Adrien Destugues
eba26aaa96 Merge trunk to the cpcmode5 branch. This gets us a more recent grafx2 with the cpcmode5 drawing. Now to make this mode optional so users can still work in regular mode :)
git-svn-id: svn://pulkomandy.tk/GrafX2/branches/cpcmode5@1719 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2011-02-13 21:49:31 +00:00
Adrien Destugues
4e60f5ad74 Import the WIP CPC-Mode5 code from the sourcearchive
git-svn-id: svn://pulkomandy.tk/GrafX2/branches/cpcmode5@1718 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2011-02-13 21:20:45 +00:00
Yves Rizoud
d0aaabf6b2 Merge of r1709 into trunk: Atari Falcon port
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@1710 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2011-02-06 19:30:55 +00:00
Yves Rizoud
fba72c9ebd Removed struct packing everywhere, except RGB 24bit struct (and thus 768-byte palettes). This might fix some issue on Caanoo, where either the packing didn't work (and the struct had wrong size) or it worked and caused unaligned reads/writes.
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@1639 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2010-10-26 22:51:07 +00:00
Yves Rizoud
dd3240f66b Fix C64 formats loading: 8000-byte hicolor was wrong, Multicolor was reading 'noise' in colors above 16 (described in issue 211 comment 34)
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@1382 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2010-03-14 18:17:56 +00:00
Adrien Destugues
b1a5103562 C64 format handling was broken. Thanks petter for fixing it :)
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@1376 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2010-03-08 10:25:18 +00:00
Yves Rizoud
3ca5322379 Reorganized source code and directory tree.
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@1375 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2010-03-05 02:53:19 +00:00