Paint Shader on objects?

Started by bobbystahr, December 31, 2008, 11:36:58 PM

Previous topic - Next topic

bobbystahr

Is this possible?...T'would be a boss late Christmas Pressie if there is. It would indeed solve a lot of problems texturing 'things'...terrains, sky and water I can do now.. ...
something borrowed,
something Blue.
Ring out the Old.
Bring in the New
Bobby Stahr, Paracosmologist

schmeerlap

I'm guessing you can't because an object hasn't got a Blend by Shader option where you would assign the Paint Shader. Here's hoping someone a little sharper than me (lots to choose from) can find a way round this.

John
I hope I realise I don't exist before I apparently die.

jo

Hi,

I had a quick try at this. I created a sphere object and a painted shader. I painted on the sphere with the painted shader, and then connected the painted shader to the colour function input of the sphere default shader. What I painted then showed up on the sphere. When I checked it from different angles it looked how I expected. This was just a quick test, I have no idea what the limitations might be or the best way to do this, but in the simplest case of painting on an object it seems to work ok.

The Painted shader can be pretty much used like any other shader, and connected to lots of different sorts of inputs. It's a bit like an image shader which you paint.

Regards,

Jo

schmeerlap

I told you. It didn't take long for a sharper tool in the box to come along and sort things out. Thanks Jo.

John
I hope I realise I don't exist before I apparently die.

Mr_Lamppost

  ;D  ;D  ;D  ;D  ;D
Smoke me a kipper I'll be back for breakfast.

AndyWelder

Mr_Lamppost, you're a cultural barbarian!!

*muttering about giving them paint and the first thing they do is painting on monuments*
:P
"Ik rotzooi maar wat aan" Karel Appel

bobbystahr

#6
I guess I should have said the ubiquitious imported 'bounding box' object...sigh..I can do procedural objects fine ie: the cloud tute.......Mr.L....you seem to have done it...how?..I think I'm stuck behind  wall of chronic dumbness lately...maybe a wee tute please and thanks.......
something borrowed,
something Blue.
Ring out the Old.
Bring in the New
Bobby Stahr, Paracosmologist

Mr_Lamppost

Quote from: AndyWelder on January 01, 2009, 09:02:40 AM
Mr_Lamppost, you're a cultural barbarian!!

*muttering about giving them paint and the first thing they do is painting on monuments*
:P
Surely I'm allowed to decorate my own obelisk.  :o

http://forums.planetside.co.uk/index.php?topic=3353.0

OK. It's not technically my obelisk, it would look daft in my garden anyhow.  The paint cleans off dead easy so not to worry.   ;D

Quote from: bobbystahr on January 02, 2009, 02:15:36 AM
I guess I should have said the ubiquitious imported 'bounding box' object...sigh..I can do procedural objects fine ie: the cloud tute.......Mr.L....you seem to have done it...how?..I think I'm stuck behind  wall of chronic dumbness lately...maybe a wee tute please and thanks.......

I'm not sure how valuable a tutorial on this would be as so much depends on what object you want to paint on, where on that object you want to paint etc. etc.   But basically the technique is the same as I used to paint in the sky.  I loaded the obelisk object then created a plane and positioned it so that it lined up with the surface I wanted to paint on.  I placed a surface layer between the objects usual surface shader and the object and created a Painted Shader as a blend shader.  The steps from there on are the same as for painting in the sky:

www.ironworld.org/mr_lamppost/TG2/guides/paintsky.htm

There is a little more involved in placing the plane and choosing the type of projection for the Painted shader.   I could probably make some notes on that aspect but I am going to be traveling this weekend and am back to work next week. . . . .
Smoke me a kipper I'll be back for breakfast.

bobbystahr

O K...I think I'll try some things but with the Paint Shader I have been having real good luck applying a brick texture to a 'procedural' pyramid, made in 0.9.43 from a .bmp and saved as a terrain and loaded into TG2, but the beauty of that is that you can see the actual sides you are painting on so it's very easy to get the texture on the correct sides and apply the correct mapping mode[see attached image]. With an imported object I see nada but the freakin bounding box so I have no idea where to paint...am I making sense...this is what's confusing me. Anyhow the truncated pyramid attached was a major step forward for me....maybe some day we'll be able to at least see wire frame representations of our imported objects...well that's on my wish list any way.. ...
something borrowed,
something Blue.
Ring out the Old.
Bring in the New
Bobby Stahr, Paracosmologist

dandelO

Nice, Bobby. Did you know by using the pyramid .bmp image as the 'shader input' of a heightfield generate node and applying 'step' interpolation method in the heightfield shader it will actually displace proper steps vertically.

I've used it here on a terrain... http://forums.planetside.co.uk/index.php?topic=4606.msg53972#msg53972

You can save the terrain created by the image map as a .ter, too.(the step displacement method isn't built into it, though, you must apply that to the heightfield shader after loading the .ter). :)

bobbystahr

Quote from: dandelO on January 04, 2009, 12:37:15 PM
Nice, Bobby. Did you know by using the pyramid .bmp image as the 'shader input' of a heightfield generate node and applying 'step' interpolation method in the heightfield shader it will actually displace proper steps vertically.

I've used it here on a terrain... http://forums.planetside.co.uk/index.php?topic=4606.msg53972#msg53972

You can save the terrain created by the image map as a .ter, too.(the step displacement method isn't built into it, though, you must apply that to the heightfield shader after loading the .ter). :)

Thanx man, and no I did not know that...back to the drawing board...so many things to experiment where does one find the time ...LOL...thanks for the tip.. ...
something borrowed,
something Blue.
Ring out the Old.
Bring in the New
Bobby Stahr, Paracosmologist

Mr_Lamppost

Quote from: bobbystahr on January 04, 2009, 12:11:26 PM
With an imported object I see nada but the freakin bounding box so I have no idea where to paint...

Although it can be done I am not sure how useful being able to use the Painted Shader on imported objects will be.  Because you can only see the bounding box it is important to have a good idea of the scale, orientation and position within the bounding box of the object so that the plane that gives a surface to paint on can be placed accurately.  It is probably a good idea to work with small planes matched to the size of the object so that you have a better idea of where you are painting.  You can do a quick low quality render to check the position of the plane before painting but on the while I expect the whole thing will be more trouble than it's worth.
Smoke me a kipper I'll be back for breakfast.

bobbystahr

[quote  but on the while I expect the whole thing will be more trouble than it's worth.
[/quote]

Not for me I feel, as the app I use to model[Imagine3D]doesn't do UV maps, but allows for designating sub groups of faces for different textures which is how I've been using the Paint Shader on terrains so far, and would really like to bring in some things I've built textured approx. like I built them. I may have to learn UV mapping and find an app, maybe the VuePLE I use, to do initial tests.. ...
something borrowed,
something Blue.
Ring out the Old.
Bring in the New
Bobby Stahr, Paracosmologist

jo

Hi,

I think it's fair to say we had no thought of using the Painted Shader on imported objects when we added it, so it's not too surprising that a painting-on-objects workflow is pushing the envelope :-). You're a pioneer bobby! :-).

Just to be clear, when I said it could be used a bit like an image shader, what I was trying to say was that you can hook it into the network in lots of places and not so much that it was easy to use as a substitute for everywhere you'd use an image shader.

Regards,

Jo

bobbystahr

Quote from: jo on January 04, 2009, 08:51:37 PM
Hi,

I think it's fair to say we had no thought of using the Painted Shader on imported objects when we added it, so it's not too surprising that a painting-on-objects workflow is pushing the envelope :-). You're a pioneer bobby! :-).

thanks for the vote of confidence jo.. ...

Just to be clear, when I said it could be used a bit like an image shader, what I was trying to say was that you can hook it into the network in lots of places and not so much that it was easy to use as a substitute for everywhere you'd use an image shader.

Regards,

Jo

Oh I realize that but was hoping...just hoping...maybe I'll figger out a workflow that works. Very grateful for it as it stands and am in fact having too much fun trying to get it to do what I want.. ...
something borrowed,
something Blue.
Ring out the Old.
Bring in the New
Bobby Stahr, Paracosmologist