Trying to fit a simple image as a planar XZ UV map on a CreateLathe object

I am trying to recreate this simple shape which is perfect for my needs (Pinball Bumper Cap)

But now I have no clue as to how to fit a planar uv map on top of it.

Here is what it is supposed to look like (made with XSI)

Any clue?

As a reference here is the model in context (the uv seems to be rotated 90 deg or spherical map?)

Aplayground would be amazing as a starting point :slight_smile: and i bet @JohnK ans his crazy maths skills would rock it !!!

It was there in the first post : Babylon.js Playground

Ohhhhhhhh so sorry completely missed it… Thanks a lot

Have you seen these resources?

They’ll likely help.

Its a matter of recalculating the uvs based on vertex positions

Note line 47 - the need to make your bumper updatable to update uvs


Sorry, this is not.

In many ways @PirateJC pointed you to the right place. You do need to know about the vertex data structure of a mesh and how to update it in order to solve the problem they way I did.

1 Like

I understand John but as I come from a software world, I was under the impression that I was looking for a simple PLANARXZ_MODE or something simple like that.

This being said I made a nice function from your script and now i can do it on the fly thanks to you.

here is the result BTW

Again thx a lot, you did fix my problem John.


@JohnK you keep impressing me :slight_smile: @polygame I can t wait to try your game :slight_smile:

thx, very nice of you :slight_smile:

This solution is Babylon.js feature material.
Projecting UV from axis is something very useful in Blender.