返回sfmesh對(duì)象中第N個(gè)紋理。

語法

texture  ST_TextureN(sfmesh sfmeshObject, int4 index);

參數(shù)

參數(shù)名稱描述
sfmeshObjectsfmesh對(duì)象。
index紋理索引編號(hào),從0開始。

描述

返回sfmesh對(duì)象中第N個(gè)紋理。

示例

select ST_TextureN('{"meshgeoms" : ["MESHGEOM(PATCH(TRIANGLESTRIP(0 0,0 10,10 10,10 0)))"],  "materials":[{"type":"db", "attributes": {"schema":"public","table":"t_material","column":"the_material","key":"num=1"}} ], "textures":[{"compressionType" : "None", "format" : "JPEG", "wrap" : "Wrap", "type" : "DB", "depth" : 3, "width" : 256, "height" : 256, "name" : "texture_name3", "size" : 72, "data" : {"schema":"public","table":"test","column":"the_texture","key":"num=1"}} ],"primitives" : [  {"meshgeom": 0, "material" : 0}],  "nodes" : [    {"primitive" : 0} ] }'::sfmesh, 0);

------------------------------
01010001010303000100000001000005000000123456FFFF