Aseprite Mega Drive Digitizer

Talk about development tools here

Moderator: BigEvilCorporation

themrcul
Very interested
Posts: 116
Joined: Fri Apr 15, 2016 2:21 pm

Aseprite Mega Drive Digitizer

Post by themrcul » Sun Nov 24, 2019 12:18 am

Hi everyone,
While thinking of what kind of art to make for a possible project with my business partner, we faced the problem of easily evaluating art on a CRT.
I thought of a few possible solutions to getting images from my computer to my CRT, from old graphics cards that can be set to 240p modes, to a retropie and coding up an art tool, etc, but then it dawned on me that why don't I just get the Mega Drive to display the art on the CRT directly?

I have a Mega Everdrive X7 which includes a USB port, so I got to work talking to the Mega Everdrive X7 using the examples provided by Krikzz.
My tests were successful and I have now built up a tool comprised of four parts which gets art directly and immediately from Aseprite to the Mega Drive with a click of a button:
1) A Mega Drive ROM which displays what it's told to by the computer through the USB port. Written in C using the brilliant SGDK by Stef.
2) A system tray app for Windows (MegaDriveSystemTrayApp.exe) which listens for commands on port 11,000 and when received, sends them over the USB port to the Mega Everdrive. Written in C#.
3) A command line app (MegaDriveDrawSocketApp.exe) which takes parameters from the command line and then connects to the system tray app on port 11,000 and sends through the commands for the system tray app to then deliver to the Mega Everdrive.
4) A lua script for Aseprite which presents a menu for the user to click on to perform different commands to the Mega Drive. It largely calls the MegaDriveDrawSocketApp.exe app with the correct parameters for stuff to then be sent to the Mega Drive.


We are likely to use Aseprite as the primary art tool for our game and so this works for us, but you can call the MegaDriveDrawSocketApp.exe command line app yourself directly if you prefer. If you run it without any parameters it will tell you what you can do and what the requirements are.

The attachment limit on this forum is small! So I have split up the file into two parts. After downloading, please rename them to MegaDriveDraw Release.zip.001 and MegaDriveDraw Release.zip.002 respectively. Then they should open. There is a readme in the archive with some simple install and usage instructions.

I hope some of you find this tool useful as we have. If I ever need to add features I will update it here in this thread.

Good luck with all of your projects!
Aseprite Render.png
Aseprite Render.png (61.45 KiB) Viewed 23843 times
Photo of it running.jpg
Photo of it running.jpg (137.65 KiB) Viewed 23843 times

themrcul
Very interested
Posts: 116
Joined: Fri Apr 15, 2016 2:21 pm

Re: Aseprite Mega Drive Digitizer

Post by themrcul » Sun Nov 24, 2019 12:18 am

Here is version 0.1 release.
Attachments
MegaDriveDraw Release 2.zip
(180.79 KiB) Downloaded 977 times
MegaDriveDraw Release 1.zip
(195.31 KiB) Downloaded 639 times

Chilly Willy
Very interested
Posts: 2984
Joined: Fri Aug 17, 2007 9:33 pm

Re: Aseprite Mega Drive Digitizer

Post by Chilly Willy » Sun Nov 24, 2019 5:39 pm

That's a really cool use of the Mega Everdrive. Now you need to expand it to showing the output from level editors. :D

themrcul
Very interested
Posts: 116
Joined: Fri Apr 15, 2016 2:21 pm

Re: Aseprite Mega Drive Digitizer

Post by themrcul » Sun Nov 24, 2019 9:31 pm

Hi Chilly,
Thanks and that's my plan - when my map builder is further along I want it connect directly to see what maps will look like on a CRT. Art just looks so different on a CRT. The map builder will connect in the same fashion as the socket app.

cero
Very interested
Posts: 338
Joined: Mon Nov 30, 2015 1:55 pm

Re: Aseprite Mega Drive Digitizer

Post by cero » Mon Nov 25, 2019 8:22 am

Software solution to a hardware problem ;) The quick solution would have been a composite out for your computer.

This is still cool, and one more use of the usb connection is good.

Chilly Willy
Very interested
Posts: 2984
Joined: Fri Aug 17, 2007 9:33 pm

Re: Aseprite Mega Drive Digitizer

Post by Chilly Willy » Mon Nov 25, 2019 2:39 pm

themrcul wrote:
Sun Nov 24, 2019 9:31 pm
Hi Chilly,
Thanks and that's my plan - when my map builder is further along I want it connect directly to see what maps will look like on a CRT. Art just looks so different on a CRT. The map builder will connect in the same fashion as the socket app.
Awesome. I imagine that things like composite blending and exact colors due to NTSC/PAL encoding are hard to get right in emulators. Using an actual MD to check the output bypasses most of the issues. And like cero said, the more software that uses certain features of common hardware, the better.
:D

themrcul
Very interested
Posts: 116
Joined: Fri Apr 15, 2016 2:21 pm

Re: Aseprite Mega Drive Digitizer

Post by themrcul » Mon Nov 25, 2019 10:43 pm

Yeah exactly, thanks fellas, I thought the same - why not use the exact output of a Mega Drive to confirm it looks like what you want, rather than any alternative?
I don't have easy access to a computer that can output composite natively anymore. So the MD was ironically the best solution for me.

TmEE co.(TM)
Very interested
Posts: 2440
Joined: Tue Dec 05, 2006 1:37 pm
Location: Estonia, Rapla City
Contact:

Re: Aseprite Mega Drive Digitizer

Post by TmEE co.(TM) » Tue Nov 26, 2019 1:31 am

Computer composhit output would look nothing like the MD output (i.e near complete lack of various artifacts) and you still have the problem of non-linear level ramp that most emulators and tools don't treat right from what I know ( viewtopic.php?f=22&t=2188 ). This is definitely the way to go ~
Mida sa loed ? Nagunii aru ei saa ;)
http://www.tmeeco.eu
Files of all broken links and images of mine are found here : http://www.tmeeco.eu/FileDen

Chilly Willy
Very interested
Posts: 2984
Joined: Fri Aug 17, 2007 9:33 pm

Re: Aseprite Mega Drive Digitizer

Post by Chilly Willy » Tue Nov 26, 2019 3:00 pm

Good point. Emulators tend to make things perfect... perfect ladders on DACs in particular. It's not as noticeable in the sound, but it is in the video, even if subtle. And even when an emulator tries to blur a line to simulate composite blending, it's not going to have the same filtering and phase shifting that occurs when a signal is converted to YIQ and back. I'm not sure is any emulator actually goes that far at all. Especially the imbalanced filtering between I and Q signals.

Sik
Very interested
Posts: 939
Joined: Thu Apr 10, 2008 3:03 pm
Contact:

Re: Aseprite Mega Drive Digitizer

Post by Sik » Wed Nov 27, 2019 1:04 am

I think I've seen emulators go that far to emulate composite, but it still fails to account for differing TV comb filter quality and such. Also there's the problem where these days you can't reasonably predict what the output method will be, to be blunt. Some people may just grab the original cables and put it in an old TV, some may use RGB or S-Video over a shiny PVM monitor, some may use OSSC or Mega Sg with their crisp HDMI output… Testing on composite is useful for knowing what details get blurred too much to be acceptable but it shouldn't be taken as the definitive outcome if you're making homebrew or hacks. You need to account for how it may look on wildly different screens.

That said, something that would be cool would be to take this further and make a full blown sprite editor that runs on the Mega Drive itself. Bonus points if you add support for the Mega Mouse or Saturn keyboard :​P
Sik is pronounced as "seek", not as "sick".

themrcul
Very interested
Posts: 116
Joined: Fri Apr 15, 2016 2:21 pm

Re: Aseprite Mega Drive Digitizer

Post by themrcul » Wed Nov 27, 2019 11:26 pm

Hey fellas,
My original plan was to show what you were drawing on the MD itself in realtime as you drew in Aseprite - as in it would send over your mouse position and colour, etc to the MD and you could see what you are doing on the CRT screen. But sadly Aseprite offers nothing in the scripting runtime as events when the user does anything on the main interface - you can only react to a button press that you define yourself in your own dialog.

A drawing tool could then of course be written for the MD, but the ROM would no longer just be a reactive program and would need drawing logic written for it, along with support for the Mega Mouse (can you even get those anymore?) - so it would be quite a bit more complicated than what it is atm.

The little 14" CRT that I have accepts component RGB input so that is what I am using in this case but it will be good to be able to see how bad it will look on composite as well. Might steer us away from certain combination of colours in the same area, etc.

vnsbr
Interested
Posts: 48
Joined: Sun Dec 17, 2017 4:13 pm

Re: Aseprite Mega Drive Digitizer

Post by vnsbr » Thu Feb 06, 2020 4:40 pm

Well aseprite is opensource so in theory could be doable still :)

Chilly Willy
Very interested
Posts: 2984
Joined: Fri Aug 17, 2007 9:33 pm

Re: Aseprite Mega Drive Digitizer

Post by Chilly Willy » Fri Feb 07, 2020 2:56 pm

Should have checked the archives when I downloaded them - both archives in the second post are corrupt.
:?

themrcul
Very interested
Posts: 116
Joined: Fri Apr 15, 2016 2:21 pm

Re: Aseprite Mega Drive Digitizer

Post by themrcul » Sun Feb 09, 2020 11:30 pm

Hmmm I'll try uploading it again when I get home. It was hard to get it uploaded in the first place due to file size limits I think.

themrcul
Very interested
Posts: 116
Joined: Fri Apr 15, 2016 2:21 pm

Re: Aseprite Mega Drive Digitizer

Post by themrcul » Sun Feb 09, 2020 11:33 pm

Ah ok I worked it out. Sorry I should have mentioned, you need to rename the files to end with .zip.001 and .zip.002. Then 7zip (and hopefully other archiving programs) will successfully open the archive.

Post Reply