Quantcast
Channel: beginners - openFrameworks
Viewing all articles
Browse latest Browse all 4929

Texturing cloth mesh with OfxBullet addon

$
0
0

@delirious.blanc wrote:

Hello!

I have been aiming to create a cloth simulation with my own images. I decided to use the OfxBullet addon (https://github.com/NickHardeman/ofxBullet) because it has a cloth example.

This is what happens when I apply a texture to the cloth mesh using a shader: https://streamable.com/t35vy3

I think the texcoords of the mesh is not being passed into the shader properly, so the texture doesn’t actually look as if its applied onto the mesh.

Here is my code: https://github.com/deliriouspointblanc/Batik-Cloth-Simulation/tree/master/test_ofxBullet_cloth

I have tried doing getMesh.getTexCoords(); but it doesn’t work. Many examples using ofMesh add the texcoords manually, but because this is wrapped up in an addon, that stuff is done for me already. I have passed textures into shaders before, but not like this.

Any pointers and hints will be really helpful, thank you!

Posts: 1

Participants: 1

Read full topic


Viewing all articles
Browse latest Browse all 4929

Trending Articles