Resources and Support
 Pixel Joint Forum : The Lounge : Resources and Support
Message Icon Topic: [tool] Pixel Checker Post Reply Post New Topic
Author Message
0xDB
Commander
Commander
Avatar

Joined: 15 March 2025
Online Status: Offline
Posts: 209
Quote 0xDB Replybullet Topic: [tool] Pixel Checker
    Posted: 22 March 2008 at 1:55pm
(Note, if you don't see the screenshot or if the link is broken, please be patient or check again later. My provider isn't guaranteeing 100% uptime and whenever it's up it's usually sloooooow.)

I had some freetime today, which I invested into writing a little Windows application that can check a piece of pixel art against various technical details, such as:
  • width/height (multiple of whatever/exactly whatever)
  • maximum allowed colors
  • maximum allowed colors per arbitrary rectangular block
  • pseudo pixel size
  • pallette conformity
[updated 1,2]
(see new screenshot / download is at end of post (redownload v2, if you still have the version that can not load gif)
new features:
  • 1 save/load restriction settings
  • 1 save error image file
  • 2 can load gif now (only checks first frame)
fixes:
  • 1 fixed a crash that occured when trying to mark pixels on pallette-indexed images
  • 2 fixed a bug in which pallette-indexed images were not loaded correctly(got stretched or skewed and auto antialiased on loading) and thus reported wrong results (loading is slower now as it copies the source image pixel by pixel to an internal 32bpp format)
planned features for next version:
  • commandline interface
[/update]

Well, I guess a picture says more than a thousand words, so here's a screenshot(sorry for suckily slow page load):
screenshot from version 1


For demonstration purposes(see screenshot) I did select values and a pallette that lead to some errors.

At programme startup, EVERY image would pass the default settings.

Long story short, here's the download:
It requires the .NET Framework Redistributable to be installed on your Windows machine. If you don't have that installed, the programme will just crash at startup.
Download Pixel Checker (v2) (Windows App)
Download Pixel Checker (Alpha) (Windows App)

edit: Almost forgot, full C# .NET source code and project file for VS2005 is included within the zip and the executable is located in the subfolder /bin/Release.



Edited by Dennis - 23 March 2008 at 9:32am
IP IP Logged
Aleiav
Commander
Commander
Avatar

Joined: 08 April 2016
Online Status: Offline
Posts: 2380
Quote Aleiav Replybullet Posted: 22 March 2008 at 2:17pm
Looks cool. Any chance of you making it for Mac as well?
IP IP Logged
0xDB
Commander
Commander
Avatar

Joined: 15 March 2025
Online Status: Offline
Posts: 209
Quote 0xDB Replybullet Posted: 22 March 2008 at 2:35pm
edit: GOOD NEWS - I just ran the executable through the Mono Migration Analyzer and it reported no issues, just green checkmarks and it said the only thing left to try is to run it under a Mono implementation on your platform of choice. :) /edit

Unfortunately I don't have access to a Mac, but there's one thing you could try:
According to the FAQ on the Mono Project, the Mac Version of Mono is capable of running .NET executables produced by Visual Studio.

I can not test this myself and I would presume that the compatibility between Mono and .NET is still not 100% but I guess it's still worth trying.

If all else fails, the source is included in the original zip, so maybe someone could just port it to Mac, using Mac native libraries or maybe even port it to Java.

I was going to work some more on the windows version tomorrow, as I plan to add more features, like "saving the error image" for example.

But really, if anyone wants to, feel free to start porting already. It's a completely free product, created to help checking pixel pieces against the most common types of restrictions that I could think of.


Edited by Dennis - 22 March 2008 at 2:47pm
IP IP Logged
Hatch
Admiral
Admiral
Avatar

Joined: 05 August 2015
Online Status: Offline
Posts: 1387
Quote Hatch Replybullet Posted: 22 March 2008 at 3:22pm
I can confirm that it runs on Mac OS 10.4.11 Tiger with a PPC chip under the hood. Unfortunately it requires X11, and you have to either launch the exe through mono in the command line, or load the solution file and build/run it from the MonoDevelop app. Most of this is beyond the casual user.

If any PJ Mac users need help running it, feel free to PM me.
IP IP Logged
jalonso
Admiral
Admiral
Avatar

Joined: 29 November 2022
Online Status: Offline
Posts: 13537
Quote jalonso Replybullet Posted: 22 March 2008 at 4:06pm
Would this work to verify weekly challenge entries.
Like you can change the values that must be passed, etc.?
What the color palette limit?
Can this be run online? or locally only?


*Sedge, PB ?? o.O


Edited by jalonso - 22 March 2008 at 4:07pm
IP IP Logged
surt
Commander
Commander
Avatar

Joined: 30 December 2015
Online Status: Offline
Posts: 413
Quote surt Replybullet Posted: 22 March 2008 at 4:26pm
With a command line interface and a constraints specification file format it could be a nice automated challenge conformance validation tool.

Edited by surt - 22 March 2008 at 4:27pm
IP IP Logged
Hatch
Admiral
Admiral
Avatar

Joined: 05 August 2015
Online Status: Offline
Posts: 1387
Quote Hatch Replybullet Posted: 22 March 2008 at 4:48pm
twould be rad if it could be turned into a php script :o But I guess it would basically have to be rewritten from scratch.
IP IP Logged
0xDB
Commander
Commander
Avatar

Joined: 15 March 2025
Online Status: Offline
Posts: 209
Quote 0xDB Replybullet Posted: 22 March 2008 at 5:22pm
It's nice to know that it runs with Mono. Thanks for testing that Hatch.

jalonso: The tool will only check the restrictions entered that make sense. e.g. at programme start, width/height restrictions are set to 0 (=no restrictions) and multiple of 1 each (=no restrictions), same goes for color restrictions and leaving the pallette empty likewise results in no limits of used colors.
So yes, the tool can check those technical restrictions arbitrarily (values are changeable).
Pallette limit: The color pallette limit is theoretically unlimited. (the current version allows loading a pallette from an image file in which case all distinct colors from that image will be put into the check pallette)

Running local/online: If the server allows running executables, I don't see why it should be restricted to local only. The server would have to have .NET or Mono installed though.

surt: I'll add commandline options tomorrow and also two buttons to load and save the whole set of restrictions (currently only the pallette is load/saveable). So tomorrow there will be a restrictions file format and then a commandline check could be like:

pixelchecker restrictionsfile.res inputimagefile.* outputlogfile.txt

And the thing would report the result to the calling application via the exit code (e.g. 0 for everything passed and other numbers to signal which checks did fail). Optionally it could also put out the error image to another file.

regarding php: Yup, rewrite from scratch would be needed for that but I think at least the algorithms could be copied (by the logic) and don't need to be rethought about. I however won't be the one porting it to php (due to a lack of php knowledge on my side).

I'll go sleeping now, feel free everyone to suggest other things while I'm off. :)


[update]
(see opening post for latest version / update information)
Against my original planning, I don't seem to have time to also add the commandline interface already today, sorry.
[/update]

[updated again]gif loading, bugfix[/updated again]



Edited by Dennis - 23 March 2008 at 9:35am
IP IP Logged
Pixel_Outlaw
Commander
Commander
Avatar

Joined: 01 September 2005
Online Status: Offline
Posts: 3829
Quote Pixel_Outlaw Replybullet Posted: 25 March 2008 at 8:25pm
Awww beat me to the punch. I had thought about making something like this.
IP IP Logged
PixelSpy
Seaman
Seaman
Avatar

Joined: 29 May 2007
Online Status: Offline
Posts: 28
Quote PixelSpy Replybullet Posted: 27 March 2008 at 5:38pm
Very cool.  Thanks for providing the code.  Now I have something fun to work on!  ;)
IP IP Logged
Post Reply Post New Topic
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum