Skip to content

Commit d7b821d

Browse files
PeterPetrikwonder-sk
authored andcommitted
fix the bug
1 parent f7c942c commit d7b821d

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/3d/pointentity.cpp

+3
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,8 @@ PointEntity::PointEntity( const Map3D &map, QgsVectorLayer *layer, const Point3D
8686
instanceDataAttribute->setVertexSize( 3 );
8787
instanceDataAttribute->setDivisor( 1 );
8888
instanceDataAttribute->setBuffer( instanceBuffer );
89+
instanceDataAttribute->setCount(count);
90+
instanceDataAttribute->setByteStride(3 * sizeof(float));
8991

9092
Qt3DRender::QGeometry *geometry = nullptr;
9193
QString shape = symbol.shapeProperties["shape"].toString();
@@ -159,6 +161,7 @@ PointEntity::PointEntity( const Map3D &map, QgsVectorLayer *layer, const Point3D
159161
}
160162

161163
geometry->addAttribute( instanceDataAttribute );
164+
geometry->setBoundingVolumePositionAttribute(instanceDataAttribute);
162165

163166
Qt3DRender::QGeometryRenderer *renderer = new Qt3DRender::QGeometryRenderer;
164167
renderer->setGeometry( geometry );

0 commit comments

Comments
 (0)