SpaceGroupUCL / depthmapX

depthmapX is a multi-platform Spatial Network Analysis Software
197 stars 52 forks source link

Replace setPixelColor with scanLine() or bits() #391

Open pklampros opened 3 years ago

pklampros commented 3 years ago

From the qt docs for setPixelColor:

Warning: This function is expensive due to the call of the internal detach() function called within; if performance is a concern, we recommend the use of scanLine() or bits() to access pixel data directly.

As found when filling pointmap pixels: https://github.com/SpaceGroupUCL/depthmapX/blob/b943241a1de680d278a327a2f80ad99f03653232/depthmapX/views/glview/glpointmap.cpp#L67