There’s testing and then there’s testing

Saturday, September 18th, 2010

Yesterday I went over to the Blender Institute to see if I could do a quicker, bigger test render. My idea was to render an image resembling my final result, but printable on A4 with my own printer. Nice idea, but… first, it wasn’t that much quicker… it was, but it still took hours. Then… the result… well… was rather disappointing.

Render results

Here’s the image as I created it.

Now… yeah I know it looks weird, but the entire idea for a Lenticular is that you slice together multiple images. In this case I used the maximum my printer can handle… an animation of 30 frames.

Here’s the rather crucial error I made in my thinking. The end result I want will be about 60cm (2 feetish) wide. But for the test I rendered the entire image at only 18cm (7inchish) wide. Which, at 600DPI is only 3600 pixels. And.. for every image you then only have one 30th of that. In this case… 120pixels per image. That is very very low resolution. You hardly get any detail at all. So the conclusion has to be that you should always print out your scene at the scale it’s going to be in the end product. And if you want a smaller test, do not resize the image, but in stead render a smaller portion of it (a crop).

The second error I made was the animation in the scene. Lenticulars work nice, but you nearly always see multiple frames at the same time (depending on your angle of view). That effect gets less the further away you stand, but it’s still there. So… if you’re animating… don’t overdo the motion! The difference between frames needs to be rather small. If an “object” is in a pixel at one frame, and the next frame a completely different object is there, that can be confusing.

And last… my lighting was far too dark. I looked at the “levels” in GIMP, and well.. it’s rather silly. So I need to look at my lighting, and consider that prints are darker than lcd screens… yah… obvious.

Solutions

For testing with a smaller part of the final image, you don’t really want to have to render the entire thing every time. It’s nicer to render just that part. Thankfully Blender has a “border render” function. So I wrote a tiny little script that calculates the “crop” of the render so I get a 18 x 18cm image (border render and crop in the render settings need to be enabled. And in this case I had the size of the render set as: 960 x 8010 pixels and at an aspect ratio of 15 to 1 (meant to be a single slice at 600DPI)

  1. import bpy
  2.  
  3. # The target pixel size
  4. xFin = 4252
  5. yFin = 4252
  6.  
  7. # The offsets (border positioning)
  8. xoff = 0.2
  9. yoff = 0.1
  10.  
  11. scn = bpy.data.scenes[0]
  12.  
  13. rnd = scn.render
  14.  
  15. xRes = rnd.resolution_x * rnd.pixel_aspect_x
  16. yRes = rnd.resolution_y * rnd.pixel_aspect_y
  17.  
  18. print('x',xRes)
  19. print('x',yRes)
  20.  
  21. xmin = 0.0 + xoff
  22. ymin = 0.0 + yoff
  23. xmax = ((1.0/xRes) * xFin) + xoff
  24. ymax = ((1.0/yRes) * yFin) + yoff
  25.  
  26. print(xmin, xmax, ymin, ymax)
  27.  
  28. rnd.border_min_x = xmin
  29. rnd.border_max_x = xmax
  30. rnd.border_min_y = ymin
  31. rnd.border_max_y = ymax
  32.  
  33. print('-- finished --')

Display clean python code for copying

import bpy

# The target pixel size
xFin = 4252
yFin = 4252

# The offsets (border positioning)
xoff = 0.2
yoff = 0.1

scn = bpy.data.scenes[0]

rnd = scn.render

xRes = rnd.resolution_x * rnd.pixel_aspect_x
yRes = rnd.resolution_y * rnd.pixel_aspect_y

print('x',xRes)
print('x',yRes)

xmin = 0.0 + xoff
ymin = 0.0 + yoff
xmax = ((1.0/xRes) * xFin) + xoff
ymax = ((1.0/yRes) * yFin) + yoff

print(xmin, xmax, ymin, ymax)

rnd.border_min_x = xmin
rnd.border_max_x = xmax
rnd.border_min_y = ymin
rnd.border_max_y = ymax

print('-- finished --')
click here to close

Help keep these files free,
and support further development!