Re: [osg-users] Painting in Textures

2009-07-01 Thread Großer Martin
Hey Maxim, first, thanks for your help. Now I know the way to manipulate values in my image. But now I have the problem to find out the right pixel in the texture. A little example: I have a complex object with a texture. All triangles of the object are randomly distributed on the texture. And I

Re: [osg-users] Painting in Textures

2009-07-01 Thread J.P. Delport
Hi Martin, you have already hinted at a search term you can use. Google for projective texturing. Also try automatic texture coordinate generation. An example in OSG of this is the OverlayNode of osgSim (this is used to project a texture onto terrain e.g.). Using this technique you can

Re: [osg-users] Painting in Textures

2009-07-01 Thread Großer Martin
Hi JP, I want to baked into the texture to create a new painted texture with the same texture coordinates like the original texture of the object. The exact use case is the creation of a heigh map. That is to say first I would like paint into the texture and after this I want to change the

[osg-users] Painting in Textures

2009-06-30 Thread Großer Martin
Hello, i would like paint on a 3d object in my scene. This object has a texture and i want to paint into this texture. My paint brush should be another texture. There are a nice solution in OSG? This problem is not trivial for me. I hope everyone can give me a example, a tip or a suitable

Re: [osg-users] Painting in Textures

2009-06-30 Thread Maxim Gammer
//Находим объект osg::ref_ptrFindNamedNodeVisitor fnnv = new FindNamedNodeVisitor(ObjectName); root-accept(*fnnv.get()); //Если такой объект есть, ищем текстуру if (!fnnv-_foundNodes.empty()) { if (fnnv-_foundNodes.size()1) std::cout Warning:

Re: [osg-users] Painting in Textures

2009-06-30 Thread Maxim Gammer
FindTextureVisitor .. in files) 2009/7/1 Maxim Gammer maxgam...@gmail.com: //Находим объект osg::ref_ptrFindNamedNodeVisitor fnnv = new FindNamedNodeVisitor(ObjectName); root-accept(*fnnv.get()); //Если такой объект есть, ищем текстуру if (!fnnv-_foundNodes.empty())