Pro Java 9 Games Development Leveraging the JavaFX APIs

(Michael S) #1
Chapter 18 ■ 3D Gameplay DesiGn: CreatinG your Game Content usinG Gimp anD Java

Figure 18-21. Create a 432-pixel image inside the 512-pixel texture with a transparent border; paste it
underneath the hoop


You are doing this so that you can undertake a similar work process (plus a 45-degree rotation) to
create the 512-pixel quadrant texture map. This is so that when the player clicks the game board square that
contains the same image, there will be a larger (decorated) version of the image content subject (question)
to preview.
Each time you use Edit ➤ Undo, you will see GIMP re-create the previous image-editing state in the
software so you can see visually when you are back to having your original 689x689 image square. If you
go back too far, you will see the entire original image from Pexels.com, and since there is also an Edit ➤
Redo command, you can go back to the square image version just as easily! The Undo/Redo feature can be
powerful for a repetitive work process like this one, where we need to create more than one texture map by
using the same original image data source.
Create a second quadrant texture, shown in Figure 18-21, by resizing the 689-pixel image to 432 pixels
using Image ➤ Image Size. Next, use the Image ➤ Canvas Size work process to center this image data
inside the transparency by increasing Canvas Size to 512 pixels and clicking the Center button. Use a Layer
to Image Size option to include the layer’s transparent pixels with the image pixels and then use Select ➤
All and Edit ➤ Copy to transfer all this image and transparency data into the OS clipboard. Select a layer
under the Steel Hoop layer and use Edit ➤ Paste as Layer to insert it.

Free download pdf