0

I would like to create a house in 3d simulation.

I can imagine taking a picture of a wall, and then pasting it on a cube in the 3d world and use it as a texture.

The problem i foresee in that is that the picture wouldnt be the texture but a warped view of the texture as the corners of the image are a slanted view of the wall, whereas whats straight infront of the camera should correctly as a texture.

Is there a program that convert an image of say, a wall, and converts it into a valid texture of that wall?

  • 2
    I think before converting a texture to actual polygons, you should look into bump maps and displacement maps. – Joonas Mar 24 at 14:56
2

Better I think to use images that have been photographed perpendicular to the textured surface being photographed. By perpendicular I mean at right angles to the textured surface.

Here's how to set up a camera like that:

enter image description here

Also you will need to use a camera with a lens that doesn't distort the image, specifically not a phone camera which has a wide angle lens which will cause distortion/warping, but something like a DSLR or Mirrorless system with interchangeable lenses, and a good quality lens with perhaps a focal length of 50mm, which will help minimise any distortion. Obviously a tripod will help you position the camera accurately and help keep it in that position.

If there is slight distortion such as pincushion or barrel distortion, these can be automatically corrected in software such as Adobe Lightroom if a profile for the lens is available, or manually by eye.

When photographing textures, correct lighting is also required. The surface would need to be evenly lit so that no part is brighter or darker than another.

TLDR: really it's all about the camera and lens used, the lighting, and the positioning of the camera.

Converting images to make them seem as though they were taken perpendicularly is possible using raster image editing software, if the perspective distortion isn't too great. Software such as Photoshop/GIMP have perspective distortion functionality, but the quality won't be as good as a photo taken properly in the first place.

Photoshop has corrective perspective distortion functionality under Edit > Perspective Warp in the main menu. And GIMP has a Unified Transform tool with a perspective option in the tool options.

  • would a 50mm with the crop sensor body work? so does that completely cancel the slanting effect? – Hermann Ingjaldsson Mar 24 at 20:19
  • Yes, I should think it would be even better since the crop factor of these cameras is around 1.5x to 1.6x or so, effectively turning a 50mm into a moderate telephoto lens. Just remember you may have to step back slightly to get more of the wall in the shot. Again if there is any slight pincushion/barrel distortion after taking the shots, Adobe Lightroom can fix it. – Billy Kerr Mar 24 at 21:58
  • A tilt-shift lens can be an alternative to editing in photoshop. Though they are a bit expensive. – Mikael Carlsson Mar 25 at 9:37
1

There is an entire category of software dedicated to this idea.

There are programs like Substance Bitmap to Material, Substance Alchemist, Quixel Mixer etc. all of which are dedicated to deriving valid tileable textures from initial photographic references. This software ecosystem is overall well developed and mature, with a bunch of very good solutions and tools, with price-points now very reasonable and the primary differentiator being workflow preferences.

There is also an emerging market / ecosystem of far more expensive and powerful tools for photogrammetry, in which multiple photos of an object are taken, and the software then extrapolates a best-guess point-cloud of the geometry, and many of those programs will also both apply per-vertex colours to each point based on the photo, some will create a best-guess meshing of the point-cloud, and will project and bake the per-vertex colour data into a best-guess texture on that mesh. Many of these are glitchy, some are not but are exorbitantly expensive - there's a very wide range here.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.