JigPlay

Version 1.1
Oct 2010
François Pessaux
What is it ?
Jigplay is
a simple jigsaw game allowing to create and play custom jigsaws from
JPG or PNG image files.
Not surprisingly, jigsaws are the well-known game in which a picture is
scattered into multiple parts randomly spreat on a board and that you
must connect in order to recover the original picture.
Status of JigPlay
JigPlay is
free software, provided with no charge ... and no warranties

This means that you do not
have anything to pay to
use it.
This also means that I
won't be responsible
in any case of whatever happens if you use it. I also have no
obligation to change, fix,
upgrade or whatever
JigPlay. This
program is
gracefully provided to who
wants and need it, in any case I remain the author, with the right to
do whatever I want
with it and its source code.
Once it will reach a stable state, sources will be released to
provide support and example for people wishing to develop on the
machine. Source code liense doesn't follow a particular licence,
instead here are the rules to apply when using this source code. The
source code can be freely distributed, it can be used as inspiration
but if you intend to extend
JigPlay reusing
entire parts of the source code, then you will have to make your
program also free as well as its source code. In other words, you can
borrow some parts but if you borrow all, then make your software and
its code as free as
JigPlay.
How to play ?
JigPlay is
completely mouse-driven, providing menus for actions other than pieces
movements. Pieces are selected by clicking on them on the play-field
with the mouse then dragging them holding the mouse button pressed
while moving it.
Starting a new game
Initially, JigPlay
doesn't show anything in the play-field. To start a new game, select
the
menu item "Game > New...".
A dialog then pops allowing to specify the picture file to use and the
number of pieces it must be scattered in and optionnally a scale factor to apply to the image.
Selecting the image to map on the jigsaw is simply done via the "Browse" button, or the cmd-b keyboard shortcut. Supported
image formats are JPG and PNG.
Pictures are not limited in size. However, if the selected image is
larger than the screen, the play-field will scroll in order to access
the whole image. Note that the size of the play-field is always larger
than the image in order to leave room enough to move pieces around and
leave the central part of the play-field available for the image
reconstruction. It is however possible to resize an image to make it
fitting a desired dimension. To do so, check the "Resize" button and move the slider
to select the desired width and height for the image. Image can only be
shrunk, not enlarged, by a factor ranging between 0.2 and 1 time the
original size (i.e. between 20% to 100% of the image size).
The number of pieces can be selected among a popup displaying the
suggested dimensions. These dimensions are computed to that, according
to the image size (possibly scaled) pieces are pretty square and not
smaller that a certain dimension (currently 30 pixels). Enforcing
quasi-square pieces makes a better visual rendering of them. Modifying
the size of the picture (either by scaling it or changing the picture)
will result in different suggested resolution because the need to get
square pieces divides the image width and height differently. When a
suggested dimension is selected, the average piece size is displayed as
information.
Saving a game
The currently running game can be suspended by saving it on the disk in
a file via the menu item "Game >
Save...". The complete state of the game is stored on the disk,
the positions of the pieces as well as the image used for the game.
This especially means that if the file used as image to start the game
disappears, it will still be possible to continue the jigsaw from a
saved game. Games are saved in file with the ".jps" extension.
Loading a saved game
Invoking the menu item "Game >
Load..." it is possible to load a game saved from the disk and
continue it at the point it was saved. Games are saved in file with the
".jps" extension.
Arranging pieces
Initially, pieces are sprout randomly on the play-field. It is
possible,
invoking the menu item "Game >
Arrange Pieces Around Corners", to sent the pieces all around
the corners of the play-field, hence leaving its central area free for
image reconstruction.
Changing the background
color
Depending on the picture background or most represented color tones,
the background of the play-field can be changed to contrast better with
the pieces by selecting the menu item "Game
>
Change
Background
Color".
Showing the picture to
rebuild
As a light help, it is possible to show in a separate window the
entire image to rebuild by selecting the menu item "Game > Show Image".
Showing the
ghost image in background on the play-field
A deeper help while solving the jigsaw is getting the image to rebuild
displayed semi-transparently in the background of the play-field. By
invoking the menu item "Game >
Toggle Image Hint", it is possible to show / display this ghost
image centered in the middle of the play-field. It is then possible to
place pieces above this model, begin helped by the background. This
menu is a toggle, i.e. invoking it several times makes the hint
displayed then hidden, then displayed again and so on.
Showing the border pieces
Usually people prefer to start assembling the borders of the jigsaw.
Using the menu item "Game > Toggle
Borders Hint" it is possible to fade all pieces but those
forming the borders. Hence, these latter get more visible and easier to
locate. Invoking this menu again restores the others pieces visibility.
Ideas for the future...
Currently JigPlay
is at an early development stage. More features are planned, among
which:
- Rotation of the pieces : currently pieces are not rotated, they
are just displaced (translation) randomly around the play-field.
Allowing them to be rotated by quarters of turns would add a bit of
challenge in the game.
- Localization in various languages : currently, all the software
is in English, other languages should make the game more friendly.
- iPhone version : ah ah,
may be the most urgent feature

History
- Version 1.1:
Bug fix of pieces selection that sometimes selected pieces that were
really not at the mouse click location, change the number of pieces
setting by proposing suggested dimensions instead of letting the user
specifying the vertical and horizontal numbers of pieces (this could
lead to uggly visual rendering of the pieces).
- Version 1.0 : Ability to change the size of the image in the game
settings, average pieces size display.
-
Versions 0.6 - 0.7 (non-released, internal development releases):
Massive cleanup in the code, bug fixes, better error handling,
performances
improvements, hint for border pieces.
- Version 0.5 : Addition of save / load game.
- Version 0.4 : First public release.
How to reach me ?
For any suggestion, comment, bug report, feel free ton contact me by
email at:
francois_pessaux<HAT>yahoo.fr
(replace
<HAT>
by
@)
and / or consult my Web page at: