Art work update is awesome, how to add missing ones?

Moderators: mdrjr, odroid

Art work update is awesome, how to add missing ones?

Unread postby GldRush98 » Sat Aug 11, 2018 10:39 am

Very nice update crash!
Is there an easy way to add in missing artwork for the end user? I'm not sure of the file format how how the springboard matches up a game to an art file. :geek:
GldRush98
 
Posts: 14
Joined: Wed Aug 08, 2018 12:58 am
languages_spoken: English
ODROIDs: ODROID-Go

Re: Art work update is awesome, how to add missing ones?

Unread postby mameise » Sat Aug 11, 2018 4:16 pm

Yes this is really amazing crash. Thanks a lot.

One small wish: If it would be possible to navigate through the games and emulators while in romart view it would be great.
Left/right - previous/next rom
Up/down - previous/next emulator
Maybe a combination of select and left/right together to jump pages in romlist.

Would be really cool :)
mameise
 
Posts: 79
Joined: Sat Jul 07, 2018 6:40 am
languages_spoken: english german
ODROIDs: ODROID-GO

Re: Art work update is awesome, how to add missing ones?

Unread postby jutleys » Sat Aug 11, 2018 10:14 pm

And it would be nice if the pack can be updated regularly to add the missing game artwork but good job.
jutleys
 
Posts: 51
Joined: Fri Jul 20, 2018 1:06 am
languages_spoken: english
ODROIDs: Odroid Go

Re: Art work update is awesome, how to add missing ones?

Unread postby crashoverride » Sat Aug 11, 2018 10:34 pm

GldRush98 wrote:Is there an easy way to add in missing artwork for the end user?

Currently, there is not. So here are the details for the "hard way":

The ESP32 processor used in the ODROID-GO has many constraints. The esp-idf SDK has no concept of a BMP, PNG, JPG, or other graphical image format. In fact, it has no concept of an image at all. Therefore, an image format was created for the artwork that consists of the following:
Width: 2 byte unsigned integer, maximum value 320 (LCD width)
Height: 2byte unsigned integer, maximum value 176 (LCD height - 32 lines on top - 32 lines on bottom)
Data: RGB565 (2 bytes) pixel data of Width * Height
(All values are little endian)

The esp-idf SDK also has no concept of a database. Therefore, a file hierarchy on the SD card is used. The CRC32 checksum of a file is used as the primary key:
/romart/system/index/crc32.art
system = nes, gb, gbc, sms, gg, col
index = first character of the CRC32
crc32.art = image file as described above with the CRC32 in hexadecimal (including leading zeros) as the name and ".art" as the extension.

To further complicate things, it is an established practice in the "scraping world" that ROM checksums do not include header information. Currently, only NES has a header (iNES) so the first 16 bytes of a .nes file are skipped when calculating the CRC32. All the other systems do no use a header.

As an example, for a .gbc rom file. First, the CRC32 of the entire file is calculated. In this example we will say its "0x1234abcd". A romart file for this would be located at:
/romart/gbc/1/1234ABCD.art
crashoverride
 
Posts: 3993
Joined: Tue Dec 30, 2014 8:42 pm
languages_spoken: english
ODROIDs: C1

Re: Art work update is awesome, how to add missing ones?

Unread postby mad_ady » Sun Aug 12, 2018 12:18 am

I'm sure a simple script could be made to take an image and a rom and produce the correct art file.
Who has time to do it?
User avatar
mad_ady
 
Posts: 4592
Joined: Wed Jul 15, 2015 5:00 pm
Location: Bucharest, Romania
languages_spoken: english
ODROIDs: XU4, C1+, C2, N1

Re: Art work update is awesome, how to add missing ones?

Unread postby rooted » Sun Aug 12, 2018 4:46 am

mad_ady wrote:I'm sure a simple script could be made to take an image and a rom and produce the correct art file.
Who has time to do it?
You are pretty good with perl are you not? ;)
User avatar
rooted
 
Posts: 5591
Joined: Fri Dec 19, 2014 9:12 am
Location: Gulf of Mexico, US
languages_spoken: english
ODROIDs: C1, C1+, C2
XU3 Lite, XU4
N1
VU7+
HiFi Shield 2
Smart Power (original)

Re: Art work update is awesome, how to add missing ones?

Unread postby crashoverride » Sun Aug 12, 2018 5:07 am

I forgot to mention that the source of the data is OpenVGDB:
https://github.com/OpenVGDB/OpenVGDB/releases

It is a Sqlite database containing systems, ROMs, and releases.
crashoverride
 
Posts: 3993
Joined: Tue Dec 30, 2014 8:42 pm
languages_spoken: english
ODROIDs: C1

Re: Art work update is awesome, how to add missing ones?

Unread postby mad_ady » Sun Aug 12, 2018 5:38 am

rooted wrote:
mad_ady wrote:I'm sure a simple script could be made to take an image and a rom and produce the correct art file.
Who has time to do it?
You are pretty good with perl are you not? ;)
I realize you're trying to hook me into doing it, but it won't work due to lack of time. But perl is not needed for the task - I think shell script is good enough. You're good with shell script, are you not? [emoji14]
User avatar
mad_ady
 
Posts: 4592
Joined: Wed Jul 15, 2015 5:00 pm
Location: Bucharest, Romania
languages_spoken: english
ODROIDs: XU4, C1+, C2, N1

Re: Art work update is awesome, how to add missing ones?

Unread postby rooted » Sun Aug 12, 2018 6:29 am

mad_ady wrote:
rooted wrote:
mad_ady wrote:I'm sure a simple script could be made to take an image and a rom and produce the correct art file.
Who has time to do it?
You are pretty good with perl are you not? ;)
I realize you're trying to hook me into doing it, but it won't work due to lack of time. But perl is not needed for the task - I think shell script is good enough. You're good with shell script, are you not? [emoji14]
I don't have a Go unfortunately, will have to wait until they are back in stock. I missed it last two times.

I was joking also, I would never want you to miss spending time with your little ones.
User avatar
rooted
 
Posts: 5591
Joined: Fri Dec 19, 2014 9:12 am
Location: Gulf of Mexico, US
languages_spoken: english
ODROIDs: C1, C1+, C2
XU3 Lite, XU4
N1
VU7+
HiFi Shield 2
Smart Power (original)

Re: Art work update is awesome, how to add missing ones?

Unread postby GldRush98 » Sun Aug 12, 2018 12:26 pm

Whew, yeah there would need to be a tool for me to handle that :lol:
Thanks for the info. All in good time I'm sure :)
Very nice update though, I do love the artwork as is!
GldRush98
 
Posts: 14
Joined: Wed Aug 08, 2018 12:58 am
languages_spoken: English
ODROIDs: ODROID-Go

Re: Art work update is awesome, how to add missing ones?

Unread postby Rewonka » Fri Aug 17, 2018 9:17 pm

Im interested in. I looked in to OPENVGDB, hm nice :) . Am I right that you convert those picture from the link in db ? Did you wrote a converter script, Crash?
Rewonka
 
Posts: 3
Joined: Fri Aug 17, 2018 6:09 am
languages_spoken: english
ODROIDs: Odroid-Go

Re: Art work update is awesome, how to add missing ones?

Unread postby crashoverride » Sat Aug 18, 2018 5:10 am

Rewonka wrote:Did you wrote a converter script, Crash?

I wrote a program to download and process the artwork for all NES, GB, GBC, SMS, GG, and COL entries in the database.
crashoverride
 
Posts: 3993
Joined: Tue Dec 30, 2014 8:42 pm
languages_spoken: english
ODROIDs: C1

Re: Art work update is awesome, how to add missing ones?

Unread postby Rewonka » Sat Aug 18, 2018 7:05 pm

crashoverride wrote:
Rewonka wrote:Did you wrote a converter script, Crash?

I wrote a program to download and process the artwork for all NES, GB, GBC, SMS, GG, and COL entries in the database.


What language did you use? Can I look in how you process the images? The software Tiled is maybe can use to make that kind of images/art?
Rewonka
 
Posts: 3
Joined: Fri Aug 17, 2018 6:09 am
languages_spoken: english
ODROIDs: Odroid-Go

Re: Art work update is awesome, how to add missing ones?

Unread postby crashoverride » Sun Aug 19, 2018 11:23 am

Rewonka wrote:What language did you use?

C#

Rewonka wrote:Can I look in how you process the images?

Code: Select all
      static Bitmap ResizeImage(Image image, int width, int height)
        {
            var destRect = new Rectangle(0, 0, width, height);
         var destImage = new Bitmap(width, height, PixelFormat.Format32bppArgb);

            using (var graphics = Graphics.FromImage(destImage))
            {
                graphics.CompositingMode = CompositingMode.SourceCopy;
                graphics.CompositingQuality = CompositingQuality.HighQuality;
                graphics.InterpolationMode = InterpolationMode.HighQualityBicubic;
                graphics.SmoothingMode = SmoothingMode.HighQuality;
                graphics.PixelOffsetMode = PixelOffsetMode.HighQuality;

                using (var wrapMode = new ImageAttributes())
                {
                    wrapMode.SetWrapMode(WrapMode.TileFlipXY);
                    graphics.DrawImage(image, destRect, 0, 0, image.Width, image.Height, GraphicsUnit.Pixel, wrapMode);
                }
            }           
                       
            return destImage;
        }
crashoverride
 
Posts: 3993
Joined: Tue Dec 30, 2014 8:42 pm
languages_spoken: english
ODROIDs: C1

Re: Art work update is awesome, how to add missing ones?

Unread postby chrispaulmhd » Tue Aug 21, 2018 6:39 am

So just placing that .tar romart file in the main folder (root is referring to having no folder right?) should display the rom art? I have the most recent firmware installed with colecovision but the rom art isnt showing up, if anyone knows what is wrong, that would be great?
chrispaulmhd
 
Posts: 17
Joined: Thu Aug 02, 2018 1:04 am
languages_spoken: english
ODROIDs: ODroid-Go

Re: Art work update is awesome, how to add missing ones?

Unread postby crashoverride » Tue Aug 21, 2018 6:50 am

The .tar file is a compressed file. The contents ("romart" folder) will need to be extracted to the SD card.
crashoverride
 
Posts: 3993
Joined: Tue Dec 30, 2014 8:42 pm
languages_spoken: english
ODROIDs: C1

Re: Art work update is awesome, how to add missing ones?

Unread postby chrispaulmhd » Tue Aug 21, 2018 7:31 am

Oh weird. So you have to uncompress it twice.. Uncompress the .tgz and then uncompress the .tar.. okay thank you.
chrispaulmhd
 
Posts: 17
Joined: Thu Aug 02, 2018 1:04 am
languages_spoken: english
ODROIDs: ODroid-Go

Re: Art work update is awesome, how to add missing ones?

Unread postby chrispaulmhd » Tue Aug 21, 2018 7:35 am

Will roms have to be titled correctly to display rom art? I'm unzipping archive into sd card right now.
chrispaulmhd
 
Posts: 17
Joined: Thu Aug 02, 2018 1:04 am
languages_spoken: english
ODROIDs: ODroid-Go

Re: Art work update is awesome, how to add missing ones?

Unread postby chrispaulmhd » Tue Aug 21, 2018 7:40 am

Hm... they still aren't displaying. I wonder why... Do I have to put the go-play.fw on at the same time, I have the most recent go-play.fw (08/10) on my odroid. Im not sure what is wrong.
chrispaulmhd
 
Posts: 17
Joined: Thu Aug 02, 2018 1:04 am
languages_spoken: english
ODROIDs: ODroid-Go

Re: Art work update is awesome, how to add missing ones?

Unread postby crashoverride » Tue Aug 21, 2018 7:48 am

chrispaulmhd wrote:Oh weird. So you have to uncompress it twice.

A .tgz file is .tar file that is gzip compressed. On Linux/Mac, it is treated as a single entity. Windows tools may treat it as a file within a file.

chrispaulmhd wrote:Will roms have to be titled correctly to display rom art?

The checksum (CRC32) of the file is used to match a ROM to its artwork. The filename of the ROM is not used.

chrispaulmhd wrote:Do I have to put the go-play.fw on at the same time, I have the most recent go-play.fw (08/10) on my odroid. Im not sure what is wrong.

The go-play.fw 20180810 or later supports the game art. Not all titles have artwork available. If no artwork is displayed, ensure the "romart" folder is in the root of the SD card. There should be 3 folders at the root of the SD card "odroid", "roms", and "romart".
crashoverride
 
Posts: 3993
Joined: Tue Dec 30, 2014 8:42 pm
languages_spoken: english
ODROIDs: C1

Re: Art work update is awesome, how to add missing ones?

Unread postby chrispaulmhd » Tue Aug 21, 2018 7:53 am

Those are the three folders I have, I have the most recent go-play installed. If there is no artwork available there is still a placeholder image used correct?
chrispaulmhd
 
Posts: 17
Joined: Thu Aug 02, 2018 1:04 am
languages_spoken: english
ODROIDs: ODroid-Go

Re: Art work update is awesome, how to add missing ones?

Unread postby chrispaulmhd » Tue Aug 21, 2018 7:58 am

Do I have to do anything when I drag over the go-play.fw, like after I turn on the odroid go? Because I dragged over the most recent go-play and it works properly.
chrispaulmhd
 
Posts: 17
Joined: Thu Aug 02, 2018 1:04 am
languages_spoken: english
ODROIDs: ODroid-Go

Re: Art work update is awesome, how to add missing ones?

Unread postby chrispaulmhd » Tue Aug 21, 2018 7:59 am

I know I have the right device firmware for it because I have coleco vision installed. If I cant get it to work.. oh well.
chrispaulmhd
 
Posts: 17
Joined: Thu Aug 02, 2018 1:04 am
languages_spoken: english
ODROIDs: ODroid-Go

Re: Art work update is awesome, how to add missing ones?

Unread postby crashoverride » Tue Aug 21, 2018 8:05 am

The go-play version is displayed at the bottom on the emulator selection screen. It should start with "Ver. 20180810-". If artwork for the ROM can not be found, a placeholder is displayed.
crashoverride
 
Posts: 3993
Joined: Tue Dec 30, 2014 8:42 pm
languages_spoken: english
ODROIDs: C1

Re: Art work update is awesome, how to add missing ones?

Unread postby chrispaulmhd » Tue Aug 21, 2018 8:15 am

Oh okay, mine says 0726.. I added the 0810 go-play.. i'm surprised the odroid still works if I didnt add it properly.. What do I have to do after dragging over the go-play.fw.. I thought I just had to drag it over, I know I dont have to flash anything because its not device firmware.
chrispaulmhd
 
Posts: 17
Joined: Thu Aug 02, 2018 1:04 am
languages_spoken: english
ODROIDs: ODroid-Go

Re: Art work update is awesome, how to add missing ones?

Unread postby chrispaulmhd » Tue Aug 21, 2018 8:31 am

okay I need to hold down power + b to get it to update to that firmware but when I hold power + b when I turn it on nothing happens?
chrispaulmhd
 
Posts: 17
Joined: Thu Aug 02, 2018 1:04 am
languages_spoken: english
ODROIDs: ODroid-Go

Re: Art work update is awesome, how to add missing ones?

Unread postby crashoverride » Tue Aug 21, 2018 8:32 am

To update the applicaion, turn the ODROID-GO off. Hold the B button. With the B button held, turn the device on. Continue holding B until the application menu appears (5 seconds).

Chose 'Go-Play' from the application list. After selecting, the title "Go-Play (20180810)" should be displayed. If it is older, there is an issue with the go-play.fw file which should be located in "odroid/firmware" on the SD card.
crashoverride
 
Posts: 3993
Joined: Tue Dec 30, 2014 8:42 pm
languages_spoken: english
ODROIDs: C1

Re: Art work update is awesome, how to add missing ones?

Unread postby crashoverride » Tue Aug 21, 2018 8:33 am

chrispaulmhd wrote:when I turn it on nothing happens?

Flash the latest device firmware to enable the application menu:
viewtopic.php?f=158&t=31513
crashoverride
 
Posts: 3993
Joined: Tue Dec 30, 2014 8:42 pm
languages_spoken: english
ODROIDs: C1

Re: Art work update is awesome, how to add missing ones?

Unread postby chrispaulmhd » Tue Aug 21, 2018 8:53 am

Awesome! figured it out. I coulda swore I had 07/27 flashed.. but I had 07/26 flashed. Good job with the artwork! It looks great on my odroid!
chrispaulmhd
 
Posts: 17
Joined: Thu Aug 02, 2018 1:04 am
languages_spoken: english
ODROIDs: ODroid-Go

Re: Art work update is awesome, how to add missing ones?

Unread postby ballboff » Sun Aug 26, 2018 3:09 am

Is this supposed to work on coleco? I can't get any of my cover art to show for this system
ballboff
 
Posts: 18
Joined: Tue Aug 07, 2018 4:23 pm
languages_spoken: english
ODROIDs: Go

Re: Art work update is awesome, how to add missing ones?

Unread postby crashoverride » Tue Aug 28, 2018 4:16 pm

It does work for coleco, but some popular titles do not have artwork available.
crashoverride
 
Posts: 3993
Joined: Tue Dec 30, 2014 8:42 pm
languages_spoken: english
ODROIDs: C1

Re: Art work update is awesome, how to add missing ones?

Unread postby AndreBerndt » Sat Sep 22, 2018 8:09 am

Hi @ all!
Is there a way for absolute beginners to add a missing ART file? Maybe manually with the help of Photoshop or other tools? It would be a shame to keep the collection out of date.
Crashoverride do you have any idea, as the creator of the collection? A little guide for absolute beginners without programming knowledge? I would be very grateful for a solution. Greetings from Germany
AndreBerndt
 
Posts: 4
Joined: Wed Aug 08, 2018 6:48 am
languages_spoken: german, english
ODROIDs: Odroid-Go

Re: Art work update is awesome, how to add missing ones?

Unread postby crashoverride » Sat Sep 22, 2018 8:59 am

AndreBerndt wrote:Maybe manually with the help of Photoshop or other tools?

AndreBerndt wrote:Crashoverride do you have any idea, as the creator of the collection?

I do not have familiarity with graphics tools like Photoshop. While it may be possible to configure some extension or plug-in to generate the data in the required format, I have no knowledge with regard to doing it.

AndreBerndt wrote:A little guide for absolute beginners without programming knowledge?

As stated previously in this topic, I do not know of an "easy way" to achieve the goal without programming knowledge. However, very little programming knowledge would be required; therefore, I anticipated someone in the community would provide a solution. This is compounded by the fact that I only use Linux for development as those wanting "simple" likely use Windows or Mac: its a few lines of shell script on Linux but an entire program elsewhere.
crashoverride
 
Posts: 3993
Joined: Tue Dec 30, 2014 8:42 pm
languages_spoken: english
ODROIDs: C1

Re: Art work update is awesome, how to add missing ones?

Unread postby AndreBerndt » Sun Sep 23, 2018 6:30 am

Too bad that nobody in the community solves the problem. Unfortunately, my skills are too low, but I would not have shunned the job. But hope dies last. Maybe there is still a programmer who takes care of the matter. Thanks crashoverride for your quick response. If you ever feel like writing a little program ... :-) I'm kidding. Greetings from Germany.
AndreBerndt
 
Posts: 4
Joined: Wed Aug 08, 2018 6:48 am
languages_spoken: german, english
ODROIDs: Odroid-Go

Re: Art work update is awesome, how to add missing ones?

Unread postby rooted » Sun Sep 23, 2018 9:27 pm

Gimp uses python for plug-ins.

This is old but should still apply:

https://www.ibm.com/developerworks/library/os-autogimp/
User avatar
rooted
 
Posts: 5591
Joined: Fri Dec 19, 2014 9:12 am
Location: Gulf of Mexico, US
languages_spoken: english
ODROIDs: C1, C1+, C2
XU3 Lite, XU4
N1
VU7+
HiFi Shield 2
Smart Power (original)

Re: Art work update is awesome, how to add missing ones?

Unread postby SarahC » Thu Oct 04, 2018 11:36 pm

Where's the romart.tgz file online?

I fancy writing an image converter in JavaScript - just because no one else would... =)
User avatar
SarahC
 
Posts: 18
Joined: Thu Oct 04, 2018 1:00 pm
languages_spoken: english
ODROIDs: Go

Re: Art work update is awesome, how to add missing ones?

Unread postby crashoverride » Fri Oct 05, 2018 12:11 am

SarahC wrote:Where's the romart.tgz file online?

It is linked to in the release topic:
viewtopic.php?f=159&t=31348#p226903
Optional ROM artwork:
crashoverride
 
Posts: 3993
Joined: Tue Dec 30, 2014 8:42 pm
languages_spoken: english
ODROIDs: C1

Re: Art work update is awesome, how to add missing ones?

Unread postby SarahC » Fri Oct 05, 2018 1:06 am

Thank you!
User avatar
SarahC
 
Posts: 18
Joined: Thu Oct 04, 2018 1:00 pm
languages_spoken: english
ODROIDs: Go

Re: Art work update is awesome, how to add missing ones?

Unread postby SarahC » Fri Oct 05, 2018 12:56 pm

---------------------
Purpose:
The webpage is to provide a non-technical person the ability to add one or two new images to their system - perhaps for a favourite game they're playing that doesn't have it's Art image in the main ROM database crashoverride processed.

Required OS / Device:
Any device that has a Chrome browser and ability to save to Micro SD card. (Will update for other browsers)
So that's netbooks, Chromebooks, laptops, PC's, Mac's, mobile phones, Raspberry Pi...

Windows
To use Chrome Browser on Windows, you'll need:
Windows 7, Windows 8, Windows 8.1, Windows 10 or later
An Intel Pentium 4 processor or later that's SSE2 capable
Note: Servers require Windows Server 2008 R2, Windows Server 2012, Windows Server 2012 R2, or Windows Server 2016.
Mac
To use Chrome Browser on Mac, you'll need:
OS X Yosemite 10.10 or later
Linux
To use Chrome Browser on Linux, you'll need:
64-bit Ubuntu 14.04+, Debian 8+, openSUSE 13.3+, or Fedora Linux 24+
An Intel Pentium 4 processor or later that's SSE2 capable
Android phones.
Any Android phone that supports a fairly modern Chrome browser.

Skills required:
Basic web-browser use.
Dragging files into a browser.
Dragging downloaded files onto an SD card folder.

---------------------


I've got the JavaScript and HTML in place that:

1: Loads an image ( Jpeg / Png / Gif / WebP / APng / SVG / XBM / Ico / Bmp) [chrome]
2: Resizes the image keeping the aspect ratio correct.
3: Converts to RGB565, and saved as bytes using little-endian format.
4: Adds the Art header using little-endian format.
5: Save's the Art file to disk.

I've still got a lot to do:

1: Add drag and drop interface for the ROM and ROM artistic image.
2: Calculate the CRC32, missing out any headers.
3: Output an example path on the page: " / [romart] / [system] / [index] / [crc32].art "
4: Set the file download's name to be "[crc32].art"

Here's the first section involving all the byte manipulation, and Art file download and previewing Art files.
Tested only in Chrome, the demo functionality can be used here:
https://codepen.io/SarahC/pen/dgMLjR

The end result will be two drop zones, where the user just drops the ROM file to calculate the filename for the Art file.
The other drop zone will be the one that creates the Art image format. (complete)
Once both are dropped, the download link will become available.

Nothing gets uploaded anywhere - it's all done in-browser, with no code leaving the users PC.
Last edited by SarahC on Fri Oct 05, 2018 2:10 pm, edited 7 times in total.
User avatar
SarahC
 
Posts: 18
Joined: Thu Oct 04, 2018 1:00 pm
languages_spoken: english
ODROIDs: Go

Re: Art work update is awesome, how to add missing ones?

Unread postby rooted » Fri Oct 05, 2018 1:59 pm

That's really cool SarahC, good work.
User avatar
rooted
 
Posts: 5591
Joined: Fri Dec 19, 2014 9:12 am
Location: Gulf of Mexico, US
languages_spoken: english
ODROIDs: C1, C1+, C2
XU3 Lite, XU4
N1
VU7+
HiFi Shield 2
Smart Power (original)

Re: Art work update is awesome, how to add missing ones?

Unread postby SarahC » Fri Oct 05, 2018 2:02 pm

Thank you!
I've got work all day again today, but I should be able to finish it this weekend. =)
User avatar
SarahC
 
Posts: 18
Joined: Thu Oct 04, 2018 1:00 pm
languages_spoken: english
ODROIDs: Go

Re: Art work update is awesome, how to add missing ones?

Unread postby rooted » Fri Oct 05, 2018 2:11 pm

I'm sure a lot of people will use and appreciate it.

A tool that takes out all the guesswork making this process easy peasy is just what the doctor ordered :)
User avatar
rooted
 
Posts: 5591
Joined: Fri Dec 19, 2014 9:12 am
Location: Gulf of Mexico, US
languages_spoken: english
ODROIDs: C1, C1+, C2
XU3 Lite, XU4
N1
VU7+
HiFi Shield 2
Smart Power (original)

Re: Art work update is awesome, how to add missing ones?

Unread postby SarahC » Fri Oct 05, 2018 2:16 pm

If it even stops just one person from getting irritated by an empty preview image - it's worth it. =)
User avatar
SarahC
 
Posts: 18
Joined: Thu Oct 04, 2018 1:00 pm
languages_spoken: english
ODROIDs: Go

Re: Art work update is awesome, how to add missing ones?

Unread postby SarahC » Fri Oct 05, 2018 8:36 pm

I've finished the first version of the program - but I don't have my Go on me to test it works correctly.

I've checked the images on the PC, and the CRC calculation and it all looks ok - but it's not had its output put on a live system yet.

It uses a three step "wizard" :
https://codepen.io/SarahC/pen/qJNYoZ?editors=1010
User avatar
SarahC
 
Posts: 18
Joined: Thu Oct 04, 2018 1:00 pm
languages_spoken: english
ODROIDs: Go

Re: Art work update is awesome, how to add missing ones?

Unread postby meveric » Sat Oct 06, 2018 12:17 am

The CRC calculation is incorrect the resulting image is fine though.


Now if I only knew why the image size is totally messed up in this art in your image format, but works anyway I would be rather happy.
Images from you or Crash:
Code: Select all
$ identify 0FDC9FB1.art
0FDC9FB1.art ART 176x65535 176x65535+0+0 1-bit sRGB 2c 62KB 0.000u 0:00.000

Image size 176x65535 (WTF?)
standard coverted image:
Code: Select all
identify C575A831.art
C575A831.art ART 176x99 176x99+0+0 1-bit sRGB 2c 2.19KB 0.000u 0:00.000

Although the file format and color depth etc. is identical the geometry is shown correctly, but the size is much differently
I really would like to know what's the correct picture format that is used here.

Edit:
Well turns out identify doesn't work on Crashoverrides .art files and the output has nothing to do with the actual picture format -.-
Donate to support my work on the ODROID GameStation Turbo Image for U2/U3 XU3/XU4 X2 X C1 as well as many other releases.
Check out the Games and Emulators section to find some of my work or check the files in my repository to find the software i build for ODROIDs.
If you want to add my repository to your image read my HOWTO integrate my repo into your image.
User avatar
meveric
 
Posts: 9186
Joined: Mon Feb 25, 2013 2:41 pm
languages_spoken: german, english
ODROIDs: X2, U2, U3, XU-Lite, XU3, XU3-Lite, C1, XU4, C2, C1+, XU4Q, HC1, N1, Go

Re: Art work update is awesome, how to add missing ones?

Unread postby SarahC » Sat Oct 06, 2018 12:28 am

Hi meveric,

My CRC's screwed? The quick test I did on 5 bytes didn't pick it up - I must have missed something.

Have you got a link to the source image you're using, and the resulting Art file - I can work off the same data then.

There's no compression - so I don't know why the files are different length if they use the same dimension image. This I will look into.

The file example you give the dimensions of "176 x 65535" would start with the bytes 0, 176, 255, 255, ....
When I was checking my files the bytes were always 0, x, 0, x as both width and height were below 256, and therefore fitted in the lower significant byte.
Again - this I will look into, if you can provide some files?

Thanks!

--------------------
EDIT:
Ahhh - I didn't realise "Identify" wasn't "Art" compatible. After a look I see its an imagemagick.org tool.
I still need to do some testing in the morning though!

"I really would like to know what's the correct picture format that is used here."
It's 2 bytes for the width, then 2 bytes for the height, then the image encoded in two bytes per pixel, using RGB 565 - where 5 bits are for red, 6 for green, and lastly 5 for blue.
There's no compression, or identifying bytes at the start (such as ASCII for PNG). Just 4 bytes for the dimensions and then enough 16bit words to draw a RGB565 image of those dimensions.
User avatar
SarahC
 
Posts: 18
Joined: Thu Oct 04, 2018 1:00 pm
languages_spoken: english
ODROIDs: Go

Re: Art work update is awesome, how to add missing ones?

Unread postby meveric » Sat Oct 06, 2018 12:49 am

If you have a linux (Debian/Ubuntu) system (for example another ODROID) you can install the package: libarchive-zip-perl
it comes with a tool called crc32 which will give you the correct CRC32 sum for your ROMS (except for the nes where you have to cut off the first couple bytes, but that's very easy to do as well).
simply do crc32 <romfile> and you already have the correct value.

I understand how you do the conversion of the picture manually, I just wished I knew how to do this with the "convert" tool from ImageMagick.
It's a very powerful tool that can do tons of conversions on-the-fly rather easy, for example:
Code: Select all
convert input.png output.jpg
or
Code: Select all
convert input.png -resize 320x240 -depth 8 output.bmp

The things you can do with that thing is amazing, but you'd have to know the correct parameters for the conversion.
Donate to support my work on the ODROID GameStation Turbo Image for U2/U3 XU3/XU4 X2 X C1 as well as many other releases.
Check out the Games and Emulators section to find some of my work or check the files in my repository to find the software i build for ODROIDs.
If you want to add my repository to your image read my HOWTO integrate my repo into your image.
User avatar
meveric
 
Posts: 9186
Joined: Mon Feb 25, 2013 2:41 pm
languages_spoken: german, english
ODROIDs: X2, U2, U3, XU-Lite, XU3, XU3-Lite, C1, XU4, C2, C1+, XU4Q, HC1, N1, Go

Re: Art work update is awesome, how to add missing ones?

Unread postby SarahC » Sat Oct 06, 2018 1:01 am

https://www.imagemagick.org/discourse-s ... hp?t=33344

They look to be using "-define bmp:subtype=RGB565" to set the bit depth.
Although someone mentions the height is a negative number. (which would explain why you see 65535 for the height earlier!)

I'm not sure it can make (width/height/pixels) width-LH, height-LH, 565-LH, 565-LH, 565-LH, 565-LH, 565-LH,............... files to match up perfectly.


>magick convert cam1.bmp -define bmp:subtype=RGB565 test.bmp
User avatar
SarahC
 
Posts: 18
Joined: Thu Oct 04, 2018 1:00 pm
languages_spoken: english
ODROIDs: Go

Re: Art work update is awesome, how to add missing ones?

Unread postby SarahC » Sat Oct 06, 2018 1:49 am

I've fixed the CRC32 calculation - I wasn't checking for NES ROM headers properly, and was cutting off headers from other ROM's that weren't there.
User avatar
SarahC
 
Posts: 18
Joined: Thu Oct 04, 2018 1:00 pm
languages_spoken: english
ODROIDs: Go

Re: Art work update is awesome, how to add missing ones?

Unread postby SarahC » Sat Oct 06, 2018 2:44 pm

I've added a toggle to add dithering, to remove any color banding you might see, and also added info about where to put the downloaded file:

https://codepen.io/SarahC/details/qJNYoZ/
User avatar
SarahC
 
Posts: 18
Joined: Thu Oct 04, 2018 1:00 pm
languages_spoken: english
ODROIDs: Go


Return to Game Emulators

Who is online

Users browsing this forum: No registered users and 4 guests