I'd like to create a 3D label in Asymptote that has a "background," effectively giving the label the look as though it were printed on poster board. I don't care if this background conforms to the Billboard effect when the 3D image is rotated; my only need here is for a static picture. I need the label to stand out against the surface behind it.
I know I could fake it by placing a white plane behind my label, but I don't know how to form this plane properly - how to correctly find the normal of the plane so that it looks rectangular from the viewpoint.
Here's a MWE, wherein the text of the label gets a little "lost" in the lines of the surface behind it.
import graph3;
size(200,200,IgnoreAspect);
currentprojection=orthographic(5,5,1);
defaultrender.merge=true;
triple f(pair t) {
return (t.y*cos(t.x),2*t.y*sin(t.x),t.y);//
}
surface s=surface(f,(0,0),(2*pi,2),32,32,Spline);
draw(s,emissive(white),meshpen=black+.2mm);
label("plot of $x$",(2,2,1.5));
I use TikZ for some of my graphics, and there it is a simple manner to have the node drawn with a solid background color making the text easy to read. I am basically looking for the same effect here.
MWE
of the scene with labels for which you'd like to add a background.