Jump to content

Border around a triangle


You are about to reply to a thread that has been inactive for 4710 days.

Please take a moment to consider if this thread is worth bumping.

Recommended Posts

Easy for you, I hope, but please help me.

I want to make a triangular prism, with a border that will run around the edges of the triangles. Imagine a triangle with a twisty line running along all the sides, but the part of the triangle inside the lines is smooth (or brick or whatever).Wish I could draw a picture to make sure you know what I mean. This is an architectural ornament like you might see on the two triangular ends of a sloped roof.

How can I apply a texture to the prim faces on the triangular ends to get this effect?

 

Thanks!

Link to comment
Share on other sites

Thanks for the quick answer. I am looking forward to trying out planar mapping. And here's a picture. Remember that the prim face is triangular. What I want is a border around the edges.

 

Safety.jpg

Of course what I have in mind is more pleasing than this, but the question will be clear.

Link to comment
Share on other sites

It's not a sculpt at all, just a regular old prim shaped like a triangular prism. It has five faces, two triangles on the ends and rectangles for the rest. I am trying to texture the triangular ends with a border that fits.

Thanks for helping!

Link to comment
Share on other sites

with planar mapping you can use the image above as-is (assuming the angles are right) on prims that are pinched or cut into triangular shapes.... some prims use planar mode by default for faces (the tops of cylinders IIRC).

planar mode applies textures projection style onto the surface, rather than wrapped, so it's not well suited to curved surfaces like spheres or torii (with few exceptions)

Link to comment
Share on other sites

What happens when you try to apply a simple square texture with a border?

Apply a square texture (is there any other kind really?) to a rectangle, and then cut the rectangle into a triangle using path cut. You end up with the border along two sides of the triangle. I want the border on three sides. Here's a screen shot from SL showing the kind of thing. The triangle piece on top is one prim (you see a triangle, but the prim has five sides, two of them triangular).

Unfortunately, I can not edit this object to see how the texture was applied.

Triangle border.jpg

Link to comment
Share on other sites

heh actually, I bet if you edit that prim, and removed the cuts, you'd see that missing parts are just more texture that is cut away by the prim parameters... so all you would do is make a triangle inside of your flat texture, and apply it.

Optimally, your base corners would be at the bottom and your point at the top center, then change the repeats to 2 and offset to .5 for the height. sub optimally, you could use the center of the image as your top point, and not bother with repeats and offsets, but that means your texture is twice as big as you need it.

Link to comment
Share on other sites

I think your best bets, in order, are (a) use two prims, (b) make a tsexture with the right image to fit, © learn to make mesh where you have complete control over the UV mapping.

Meanwhile, here is a semi-solution just for fun. No real use because it has to be a flat plane and it can only be a 90 degree angle, but anyway....

The bottom thing is a squashed cube to show the texture. The top thing is a cube, dimensions [1,1,0.01], pathcut [0.25, 0.75], tapered[0.2, 0.2]. The same texture is applied to these three visible faces, the main triangle is U=0.707 (1/sqrt(2)), V=1.00, rotation=135. offsetU=0.000, offsetV=0.500. Both faces have U=V=rotation=0, offsetU=0.000, offsetV=0.500. Texture mapping is Planar.

bordertst2.jpg

Link to comment
Share on other sites

My preferred solution is to make the texture itself a triangle, like this.....

Lamp frame.jpg

Anything white in this image is actually transparent in the real image I uploaded to SL.  It's applied to a triangular face (in my case, one of the 4 triangular faces on a tetragonal pyramid), using planar mapping, with the repeats exactly as Void suggested.  It works perfectly.

Link to comment
Share on other sites

might take a week to LEARN, but if you can't build it in few mins then I'd suggest learning more....

the meantime, even if it took 2 weeks (I have no clue how long it actually took), Drongle's 2 prim* mesh staircase with proper physics impressed me quite a bit.

*2 Prims is a reported cost, it's really a single object, but well below what it would have taken for ANY other method

Link to comment
Share on other sites

What?... isn't anyone going to ridicule my use of Sculptypaint by showing me a perfect mesh triangle that only took a week to design?

There's nothing riduculous about Sculptypaint, but a challenge is a challenge...


trisign.jpg

56 Blender & Gimp minutes (still a novice) :smileyhappy:

Link to comment
Share on other sites

"...well below what it would have taken for ANY other method."

I'm not so sure. I am half way through making the exact same thing with sculpties, and I am certain I can do it with two. It should survive one LOD step, which the mesh doesn't, but it's much more thought and work than with simple mesh, especially getting it reasonably texturable and minimising shading artefacts.  Of course the real problem with the sculpty is the need for extra prims to be able to walk on it. So far, this seems to cost more than making an equivalent simple physics shape for a mesh.

:smileysurprised: BUT I just linked a couple of cubes to a sculpty and set the physics shape type of the sculpty to "None", and it worked as it does for meshes ... the standard cubes (no distortions other than strectch)  count as less than one prim. We don't know how much they will cost come release time, but if this mechanism is left applying to sculpties as well as meshes, there could be big saving in costs of invisible prims used for sculpty physics. "None" is much better than "Phantom" as they can be linked (have to be to get the saving.)

Note that none of this is guaranteed to survive into the mesh release.

Link to comment
Share on other sites

 


Drongle McMahon wrote:

"...well below what it would have taken for ANY other method."

[...] Of course the real problem with the sculpty is the need for extra prims to be able to walk on it. So far, this seems to cost more than making an equivalent simple physics shape for a mesh.[...]

and that's the key to what I was saying... even if someone can whip that staircase out of a single sculpt, you'd still need 2 prims minimum to catch the same physics... so that's a 50% minimum increase (granted it's an extreme case, I doubt most will hit such a circumstance)

 

Link to comment
Share on other sites

Here's a better bordered triangle cube: cube [1,1,0.01]; path cut [0.25,0.75]; taper [1.00, 1.00]; shear [0.18, 0.18]; - that gives a squashed pyramid. Then adjust top slice down from 1.00 to give a whole range of inner triangle sizes. Using planar texture mapping and the following settings (multiplied as approipriate) for textures [u, V, Rot, Uoff, Voff]: triangle face [0.25, 0.25, -45, 0, 0]; left and right uncut edges [0.25, 0.75, 180, 0, 0.02]; left half cut face [1.00, 0.25, 1.00, 90, 0, 0]; right half cut face [0.25, 1.00, 0, 0, 0]. Apply horizontal texture flip to right edge and right cut faces. This gives correct flow of texture from uncut to cut faces. left and right are mirrored, The bottom is still not the edge of the texture. If you try it at other angles, the texture gets sheared. Doesn't solve the origional question, but makes quite a useful object. The textures stay correct as you adjust the slice point.

trisix.jpg

Link to comment
Share on other sites

You are about to reply to a thread that has been inactive for 4710 days.

Please take a moment to consider if this thread is worth bumping.

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
 Share

×
×
  • Create New...