Thomas Bernard
f3ba6d3205
Add ability to save C64 FLI pictures for a 1 layer image
...
add function Save_C64_fli_monolayer()
The algorithm used is :
- first choose the lowest value from all possible background colors for each line
- first the lowest value from the possible colors for color RAM
- encode bitmap and screen RAMs
2018-11-10 21:32:52 +01:00
Thomas Bernard
3720e45246
Improve doxygen comments of C64 functions
2018-11-10 21:32:52 +01:00
Thomas Bernard
970b9a179c
fix for building with MS Visual C++ 2010
...
snprintf should be defined to _snprintf on this compiler
2018-11-09 12:50:40 +01:00
Thomas Bernard
8b38c36090
cleanup in Load_C64()
2018-11-06 23:52:16 +01:00
Thomas Bernard
f207567d38
doxygen for Load_C64_fli()
2018-11-06 23:26:42 +01:00
Thomas Bernard
4b52718c1e
display error message to the user when saving C64 FLI
2018-11-06 22:31:55 +01:00
Thomas Bernard
cb5dd7ae69
reindent Save_C64_multi() and Save_C64_fli()
2018-11-06 22:14:15 +01:00
Thomas Bernard
2b22a7fe1d
C64 pictures are 16 colors (4bpp)
2018-11-06 22:13:34 +01:00
Thomas Bernard
5f6c1a2c55
improved comments / readability of Save_C64_multi() + add debug log
...
The algorithm to choose the background color is improved.
2018-11-06 20:57:21 +01:00
Thomas Bernard
06f8809337
Fix in Save_C64_multi()
2018-11-06 20:50:51 +01:00
Thomas Bernard
0ce37b39b6
error handling in Save_PI1()
...
Signed-off-by: Thomas Bernard <miniupnp@free.fr>
2018-07-02 19:58:26 +02:00
Thomas Bernard
8a018fdb82
fix Save_PI1()
...
the color cycling information was always overwriting the last 32 bytes
so the last 16 pixels were almost always saved black
2018-07-02 14:25:14 +02:00
Thomas Bernard
c53b86d6c9
Fix Endian dependent code when compiled without SDL or SDL2
...
Signed-off-by: Thomas Bernard <miniupnp@free.fr>
2018-07-02 11:38:52 +02:00
Thomas Bernard
4d86b8a0c1
change all references to SDLK_xxxxx to KEY_xxxx
...
+ some fixes
2018-07-02 11:38:51 +02:00
Thomas Bernard
77005eb780
use screen.h instead of sdlscreen.h, etc.
...
Create grafx2-win32 MSVC++ project
create keycode.h
various fixes
2018-07-02 11:38:51 +02:00
Thomas Bernard
92facef46d
Convert comments to UTF-8
...
most were encoded in Latin1 / CP1252
but a few lines in op_c.c were using IBM437/850 !
2018-06-26 11:37:19 +02:00
Thomas Bernard
c6014da99f
FLI/FLC: fix loading of "empty" frames
2018-04-16 13:29:03 +02:00
Thomas Bernard
bb7b187275
Load FLI/FLC autodesk animator files.
2018-04-16 07:03:17 +00:00
Thomas Bernard
187c7d53e3
Fix a few warnings (from MS Visual Studio 2015)
2018-04-06 16:45:35 +02:00
Thomas Bernard
3e82bd0649
Test_PAL/Load_PAL: replace fread() by Read_bytes()
2018-03-15 13:40:14 +01:00
Thomas Bernard
531cda58b6
Fix Test_GPL() and Load_GPL()
2018-03-15 13:24:59 +01:00
Thomas Bernard
3ab746ef29
fileformats.c: Get rid of "unreferenced argument" Warning
2018-03-15 12:21:22 +01:00
Thomas Bernard
cd8291b6ff
loadsave: change Test_XXX functions to open file only once
2018-03-15 12:21:22 +01:00
Thomas Bernard
b039977f5f
move Test_XXX/Load_XXX/Save_XXX functions prototypes to fileformats.h
2018-03-15 12:21:16 +01:00
Thomas Bernard
f53925f4f5
Load_CM5() : clean up palette setup
2018-03-05 13:55:35 +01:00
Thomas Bernard
9e89fb665b
Load_CM5() Fix preview for CM5 format
2018-03-05 13:55:35 +01:00
Thomas Bernard
68cad3884b
Load_CM5() update comments
2018-03-05 13:55:35 +01:00
Thomas Bernard
9209cc0a5c
Load_CM5(): clear palette if configured to do so
2018-03-05 13:55:35 +01:00
Thomas Bernard
4b4a66d65c
Load_CM5() remove uneeded buffer
2018-03-05 13:55:35 +01:00
Thomas Bernard
524bdfba90
improve Test_CM5()
2018-03-05 13:55:35 +01:00
Thomas Bernard
f32eacaa01
Make compilers happy, remove warnings...
...
unsigned/signed comparaison in miscfileformat.c
unused argument in readline.c
2018-03-05 09:22:03 +01:00
Thomas Bernard
3d4f39fe36
Use Open_file_write() in Save_GPL() Save_PAL() and Save_XPM()
...
They are Text format, correctly handle line endings
according to the type
2018-02-20 15:45:45 +01:00
Thomas Bernard
3c3ef150a6
improve Test_PPH()
...
remove one TODO :)
2018-02-20 15:45:45 +01:00
Thomas Bernard
be824627ce
loadsave.c: Add functions to open file with alternate extension.
...
Used by CPC format which are in several files :
PPH format uses PPH, ODD, EVE
CM5 uses CM5 + GFX
2018-02-20 15:45:45 +01:00
Thomas Bernard
74818299a3
use Open_file_read()/Open_file_write()
2018-02-20 15:45:45 +01:00
Thomas Bernard
2bfbc03cb8
Display the bpp of the picture in the Load/Save Dialog
2018-02-18 21:11:40 +01:00
Adrian Castravete
7059271965
Add indication of offending cell in C64 formats
2018-02-13 13:31:15 +02:00
Thomas Bernard
a53d6da6ea
Add visible_image and backups to the T_Document structure
2018-01-22 16:16:39 +01:00
Adrien Destugues
5b6095f0bc
Fix all warnings and enable -Werror
...
mostly unused variables and broken indentation.
2017-05-06 15:13:50 +02:00
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