jum Posted December 14, 2017 Share Posted December 14, 2017 (edited) I have modified the online "Tiny Sprite Editor" ( http://tmtg.net/tinyspriteeditor/) made by Boris van Schooten, so that you can use it to create sprites for Atari Lynx. Double-click the .html file in the attached zip to run it. Currently you can export the sprite data as C code or ASM code (literal sprites only for now, can add RLE compressed sprites later). Usage: 1. Run the .html file in Chrome (may work in other browsers too). 2. Set the "Palette" drop down to "Atari Lynx" BEFORE you draw anything. 3. Draw a pretty picture (background must be pen 0 (black)) 4. In the "Text Format" dropdown, select "Lynx C code (literal)" 5. Click the "Export" button. 6. The C code will appear in the textbox at the bottom of the page. Note: you cannot import C code at this stage. If you want to "Save" your sprites to work on later, then export as "Data URL". Let me know how it works for you. I am sure many improvements can be made. The main purpose is to make it easier to create Lynx sprites for your projects, without having to hassle with Gimp and PCX and sprpck/sp65 and bin2c... Have fun! Also have added to github as a fork of the original: https://github.com/j...inyspriteeditor tinyspriteeditor_lynx_V1.1.zip Edited December 16, 2017 by jum 1 Quote Link to comment Share on other sites More sharing options...
+karri Posted December 14, 2017 Share Posted December 14, 2017 (edited) Such a nice editor. The literal sprites are ok for most purposes. It works in Firefox too. Edited December 14, 2017 by karri 1 Quote Link to comment Share on other sites More sharing options...
jum Posted December 14, 2017 Author Share Posted December 14, 2017 Such a nice editor. The literal sprites are ok for most purposes. It works in Firefox too. Thanks for testing Karri. Has some impressive features for a "Tiny" editor (Copy/Paste/Sprite sheets/Animation preview). Quote Link to comment Share on other sites More sharing options...
Turbo Laser Lynx Posted December 14, 2017 Share Posted December 14, 2017 Very nice stuff, thanks for sharing man! 1 Quote Link to comment Share on other sites More sharing options...
LordKraken Posted December 14, 2017 Share Posted December 14, 2017 Looks pretty cool but I haven't figure out how to modify the palette yet... or is it even possible? (having black for pen 0 is not optimal since pen 0 is also the transparent color). Quote Link to comment Share on other sites More sharing options...
jum Posted December 15, 2017 Author Share Posted December 15, 2017 (edited) Looks pretty cool but I haven't figure out how to modify the palette yet... or is it even possible? (having black for pen 0 is not optimal since pen 0 is also the transparent color). You can modify the palette in the HTML source code, or add your own palette. You can change pen 0 to pink if you prefer. Probably would be nice to be able to import a Lynx palette, either from C file data or from .gpl palette file. Let me know what format(s) would be most useful. Also have added to github as a fork of the original: https://github.com/james7780/tinyspriteeditor Edited December 15, 2017 by jum Quote Link to comment Share on other sites More sharing options...
Bochum_Boy Posted August 17, 2018 Share Posted August 17, 2018 Classical noob question: How do I implement a C-Struct array in a Lynx programm? I read the tutorial on the sprite with .o objects, any idea how to implement a TinySprite? Quote Link to comment Share on other sites More sharing options...
+karri Posted August 17, 2018 Share Posted August 17, 2018 The tiny sprite exports the bitmap as bytes. unsigned char sprite_0_0[] = { 0x7, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x7, 0x0, 0x0, 0x0, 0xf, 0x0, 0x0, 0x7, 0x0, 0x0, 0x0, 0xff, 0x0, 0x0, 0x7, 0x0, 0x0, 0xff, 0xff, 0x0, 0x0, 0x7, 0x0, 0xff, 0xff, 0xf0, 0x0, 0x0, 0x7, 0x0, 0xff, 0xff, 0xff, 0x0, 0x0, 0x7, 0x0, 0xf0, 0xff, 0xff, 0x0, 0x0, 0x7, 0x0, 0xf, 0xff, 0xff, 0x0, 0x0, 0x7, 0x0, 0xff, 0xff, 0xf, 0x0, 0x0, 0x7, 0x0, 0x0, 0xf, 0x0, 0x0, 0x0, 0x7, 0x0, 0x0, 0xf, 0xf, 0xf, 0xf0, 0x7, 0x0, 0x0, 0x0, 0x0, 0x0, 0xf0, 0x00 } In the cc65 library _suzy.h you have different type of sprite structs like: typedef struct SCB_REHVST_PAL { // SCB with all attributes unsigned char sprctl0; unsigned char sprctl1; unsigned char sprcoll; char *next; unsigned char *data; signed int hpos; signed int vpos; unsigned int hsize; unsigned int vsize; unsigned int stretch; unsigned int tilt; unsigned char penpal[8]; } SCB_REHVST_PAL; static SCB_REHVST_PAL Sastonmartin = { BPP_4 | TYPE_NORMAL,REHVST|LITERAL,NO_COLLIDE, 0, sprite_0_0, 80, 100, 0x100, 0x100, 0x000, 0x000, {0x01,0x23,0x45,0x67,0x89,0xab,0xcd,0xef} }; Then you can paint this on screen with: tgi_sprite(&Sastonmartin); tgi_updatedisplay() Quote Link to comment Share on other sites More sharing options...
Bochum_Boy Posted August 21, 2018 Share Posted August 21, 2018 Thanks Karri - that made the trick! Quote Link to comment Share on other sites More sharing options...
SlidellMan Posted August 27, 2018 Share Posted August 27, 2018 Not a bad tool, if I do say so myself. Quote Link to comment Share on other sites More sharing options...
PetrS Posted December 29, 2019 Share Posted December 29, 2019 Hi All, Currently I use the tiny sprite editor PNG export, and then imagemagick (see below) to convert to BMP so it can be processed by sprpck. convert image.png -colors 16 -type palette image.bmp The problem, of course, is that the palette gets scrambled by the conversion but at least it generates an image that can be used by sprpck. I cannot get any of the export to text to generate anything visible (including Karri's above example.) How do you use the exported text to work properly? Quote Link to comment Share on other sites More sharing options...
+karri Posted December 29, 2019 Share Posted December 29, 2019 I just checked the latest version of tinysprite-lynx and it seems to be broken. I was not able to get any sprites out of it. Quote Link to comment Share on other sites More sharing options...
juanitogan Posted July 30, 2021 Share Posted July 30, 2021 On 12/29/2019 at 1:46 AM, karri said: I just checked the latest version of tinysprite-lynx and it seems to be broken. I was not able to get any sprites out of it. The latest version from Jan 2018 works fine for me. All you need is the tinyspriteeditor_lynx.html file, set the palette to Lynx, don't draw with black (erase with black), set the text format to Lynx whatever, and hit Export to see the output text. If I ever get bored enough, I'll take the last open-source version of Aseprite (or similar) and do something similar but with palette generation too (using a palette of 16+4096 colors - the colors you copy to the first 16 slots set it). But... that's not likely unless I get around to launching a Lynx project too. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.