[osg-users] [vpb] Doubt regarding integrating shapefile with VPB

Vinoth Rajendran vinothrajendran4pro at gmail.com
Thu Feb 16 06:10:43 PST 2017


Hi Community,

I have builded a terrain database with shapefiles associated to that terrain region using VPB. I noticed that the generated .osg file has height data for shapefiles. When i load my osg file into osgViewer , it renders only terrain height map data. 

command used to generate terrain database is:

Code:
osgdemd -d terrain.tif --building build.shp -o data.osg



Why shapefile  data not getting rendered with height ? Below i have mentioned snapshot of osg file with shapefile associated datas


> Geometry {
>             UserData {
>               osgSim::ShapeAttributeList {
>                 int    "id" 407943813
>                 string "building" "yes                                                                                                                                                                                                                                                           "
>                 string "surface" "                                                                                                                                                                                                                                                              "
>                 string "landuse" "                                                                                                                                                                                                                                                              "
>                 string "leisure" "                                                                                                                                                                                                                                                              "
>                 string "natural" "                                                                                                                                                                                                                                                              "
>                 string "NAME" "Building"
>               }
>             }
>             useDisplayList TRUE
>             useVertexBufferObjects FALSE
>             PrimitiveSets 2
>             {
>               DrawArrays POLYGON 0 4
>               DrawElementsUByte TRIANGLE_STRIP 10
>               {
>                 2 4 3 5 0 6 1 7 2 4
>               }
>             }
>             VertexArray Vec3Array 8
>             {
>               637137.125 1100359.875 19.50362586975098
>               637137.75 1100343.5 19.50362586975098
>               637146.9375 1100343.875 19.50362586975098
>               637146.3125 1100360.25 19.50362586975098
>               637146.9375 1100343.875 9.503626823425293
>               637146.3125 1100360.25 9.503626823425293
>               637137.125 1100359.875 9.503626823425293
>               637137.75 1100343.5 9.503626823425293
>             }
>             NormalBinding PER_VERTEX
>             NormalArray Vec3Array 8
>             {
>               -0.4397531449794769 0.4558025300502777 0.773861289024353
>               -0.8702059388160706 -0.280549019575119 0.4050111770629883
>               0.4397531449794769 -0.4558025300502777 0.773861289024353
>               0.8702059388160706 0.280549019575119 0.4050111770629883
>               0.9724705219268799 -0.2330259680747986 0
>               0.6351727843284607 0.7723701000213623 0
>               -0.9724705219268799 0.2330259680747986 0
>               -0.6351727843284607 -0.7723701000213623 0
>             }
>             ColorBinding OVERALL
>             ColorArray Vec4Array 1
>             {
>               1 1 1 1
>             }
>           }



i further attach my .osg file for reference...

Thank you!

Cheers,
Vinoth

------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=70216#70216



-------------- next part --------------
A non-text attachment was scrubbed...
Name: data.osg
Type: application/octet-stream
Size: 502535 bytes
Desc: not available
URL: <http://lists.openscenegraph.org/pipermail/osg-users-openscenegraph.org/attachments/20170216/374da9bc/attachment-0002.obj>


More information about the osg-users mailing list