Colored texture for a shiny sphere

I like to create a texture with some text for a ball, just like a number on billard ball. I have two questions:

  1. How to make the text/texture the right size (now it is too big)
  2. How to create a texture that does not get deformed (I tried all three modes: original, projected and polar)

After that I would like to give the ball some shininess, just like a billard ball has. How to accomplish this using “Common/MatDefs/Misc/ColoredTextured.j3md”?

One way would be to just create the ball in a 3D modeling tool, like Blender. You can assign UV coords there so you can adjust them so that the texture won’t be deformed. If you don’t know how to do that, you might be able to find a free 3D generic ball model online and change the texture. But I don’t know, there might be a way without doing all that inside JME.
For shininess, do you have to use ColoredTextured.j3md? Because if the ball is dynamic, the “shine” wouldn’t be realistic. Can’t you use Lighting.j3md and use its specular for shininess?

1 Like

What @Seann999 says. Even more, your texture will probably get deformed. A square texture would simply not fit a sphere.
You still can have “view projected UV”, but if your sphere rotates, deformations would be awful.

1 Like

I’d do the following: Create a Texture – lets say 512×512 pixels copy a tv-testscreen or some geometrical unique picture in it – the put that on yout ball. Now you see exactly where in the picture you have to put your balls text and how big it has to be. Switch to your graphic programm, mark that on your texture and render again. with some iteration, you’ll get a quite precise feeling, how your 2d-Image has to look before it will get onto the ball. Depending on the actual setup, you have to make shure that you put the highest detail needed (for a billiard ball, that would b the number) in the middle of the sphere, where the texel to voxel ratio is almost 1:1.