Spreadable svg quads and svg text


I tried to generate a bunch of svg shapes and svg texts to use them in a 3d setup.

how can I generate the svg elements from a spread. actually, when I use svgtext the elements overlay in the svg renderer! (somehow logical). although when I save it to diffent filenames, all files have the same xml.

ok, I generated the svg texture into a texture buffer. thats fine.

what still bothers me are the rounded corners, no idea how they work. I would like regardless of the width of the svg quad the same corners, as in 9grid shapes in flash or css.

svg buffer test (23.6 kB)

there are several pitfalls in your patch. if you set the SVG renderer to 800x800 pixels but you have a window size of 400x300 to display it everything will look distorted.

the corner radius of the quad is a relative value from 0 to 0.5, where 0 is no radius and 0.5 means half of the side will be in the radius.

have a look at the patch:

svg_test2.v4p (30.6 kB)

thanks a lot, I haven’t seen it.

is my way to store the rendered txture in a buffer the usaual way?

that’s perfectly fine. although i admit that we could use a node which generates a SvgDocument for each slice of a spread of SvgElements which then can be redered by the SVGTexture node which is already spreadable.

the next alpha version will have two new svg nodes, Join (SVG) and AsDocument (SVG). should be up in the alpha build in about half an hour. please check their help patch to see how easy you can now render multiple textures from a spread of svg elements.