Re: How to put text on a curved surface?
- To: mathgroup at smc.vnet.net
- Subject: [mg87181] Re: How to put text on a curved surface?
- From: dh <dh at metrohm.ch>
- Date: Thu, 3 Apr 2008 05:16:22 -0500 (EST)
- References: <fsvels$sto$1@smc.vnet.net>
Hi,
here is a first attempt:
a) define a 2dim parameter space. E.g. for a Torus {0,2Pi} x {0,2Pi}
b) write your characters into the flat parameter space
c) map the 2dim parameter space into 3D
here is an example where we write two "A" characters onto a torus:
R=10;r=3;
map[p1_,p2_]:={R Sin[p1]+ r Cos[p2] Sin[p1],R Cos[p1]+ r Cos[p2]
Cos[p1],r Sin[p2]};
charA2D[p_,pos_,size_]:=Plus[#,pos]&/@{{0.5
p,p},{0.5+0.5p,1-p},{0.25+0.5p,0.5}};
txt[p_]:=Join[charA2D[p,{0,-.5},1],charA2D[p,{1.1,-.5},1]];
g1={Graphics3D[Thickness[0.02]],ParametricPlot3D[map@@@txt[p],{p,0,1}]}//Show;
g2=ParametricPlot3D[map[p1,p2],{p1,0,2Pi},{p2,0,2Pi}];
Show[g2,g1]
hope thsi helps, Daniel
P_ter wrote:
> I would like to put "Mathematica" on a curved surface, e.g. a torus.
> Can anyone help here?
> with friendly greetings,
> P_ter
>