Books in 3D

I’ve been an admirer for some time of the cool 3D images some authors are using to promote their books, and especially their box sets. I don’t have a box set yet, but I do have books and I’d love to get a little more pop in my images.

The problem is, the way people have been making those images doesn’t work for me. They involve Photoshop actions that cost money, or don’t work with Photoshop Elements which is what I use. So I thought: I’ll look into what it would take to make an Elements-friendly action.

And then I found out you can talk to Photoshop with JavaScript. Mind blown. With JavaScript, I don’t have to be locked in to a particular orientation for the image, and don’t have to worry about trying to painstakingly record a bunch of individual actions.

I’ve developed a script to create the kind of image I wanted, and to pay it forward, that script is free for anyone to use. You can download it here. This script was tested in Photoshop Elements 15, but I think it will work just peachy in older versions, and obviously the full Photoshop should have no issues with it either.

How does it work? You’ll probably want to make a copy of the script and move it into a folder where you keep your other art resources for the book in question. Open your finished cover file in Photoshop, and flatten the image if it needs flattening. (Best practice: Open the PNG file you saved instead of your raw .psd. You did save a PNG, didn’t you?) Now, open the script in a text editor and fill in the information you need:

  • What are the dimensions of the book?
  • Are the spine and back cover are included?
  • How many pixels of bleed are in the cover image?
  • Are the pages cream or paper?
  • What angle would you like to turn the book towards?
  • What size do you want for the result image file? (The 3D book will be scaled to fit that size.)

There are a couple of advanced settings you can change too, like lighting and a bit of the camera angle and settings, but those are the important ones. Now open the script in Photoshop, and let it take everything from there.

The resulting image will have a layer for each visible side of the book, a shadow layer, and also a quickie background that you may or may not care about. I removed the background for the image shown above, and that image has also been scaled down quite a bit. The script creates a very high-res image by default; you’ll probably want to leave the output resolution alone and simply scale the result when you’re done.

By default, this script is setup for a full wraparound cover with a 6″×9″ size at 300 dpi. I didn’t include any default bleed, but my covers always use 38 pixels (1/8″). If you change the angle of the book so the spine is facing away from the camera, you don’t necessarily need a spine image, just a front cover, and you can simply specify a dummy spine width. There’s already a dummy width of 1″ for the spine, but if you use a wraparound cover the spine width will be calculated for you.

So that’s it! Super simple, and all you need is Photoshop or Photoshop Elements, your cover file, and a text editor to load the script in. You don’t really need to know any JavaScript to make the appropriate configuration changes.

Update: I’ve added parameters to control the output scale and position, so you can more easily create consistently sized images of multiple books regardless of spine width (which would previously have impacted the scaling). The project is now hosted on GitHub and future modifications will be made there.

About Lummox JR

Aspiring to be a beloved supervillain
This entry was posted in Uncategorized and tagged , . Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s