File tree Expand file tree Collapse file tree 1 file changed +8
-4
lines changed Expand file tree Collapse file tree 1 file changed +8
-4
lines changed Original file line number Diff line number Diff line change @@ -1123,17 +1123,21 @@ void QgsLineString::importVerticesFromWkb( const QgsConstWkbPtr &wkb )
1123
1123
mY .resize ( nVertices );
1124
1124
hasZ ? mZ .resize ( nVertices ) : mZ .clear ();
1125
1125
hasM ? mM .resize ( nVertices ) : mM .clear ();
1126
+ double *x = mX .data ();
1127
+ double *y = mY .data ();
1128
+ double *m = hasM ? mM .data () : nullptr ;
1129
+ double *z = hasZ ? mZ .data () : nullptr ;
1126
1130
for ( int i = 0 ; i < nVertices; ++i )
1127
1131
{
1128
- wkb >> mX [i] ;
1129
- wkb >> mY [i] ;
1132
+ wkb >> *x++ ;
1133
+ wkb >> *y++ ;
1130
1134
if ( hasZ )
1131
1135
{
1132
- wkb >> mZ [i] ;
1136
+ wkb >> *z++ ;
1133
1137
}
1134
1138
if ( hasM )
1135
1139
{
1136
- wkb >> mM [i] ;
1140
+ wkb >> *m++ ;
1137
1141
}
1138
1142
}
1139
1143
clearCache (); // set bounding box invalid
You can’t perform that action at this time.
0 commit comments