Conversation
|
For what it's worth, it's been a while since I've made a PR that touched rendering (I think it was #1188...) and I have to say that things like It might even be possible to claw back some performance by converting them to structs since they're small and potentially could be allocated every render. |
Thanks! I made them because I kept confusing myself passing
If I'm going to refactor ScottPlot 4, it'll probably be to favor readability and portability over performance. Switching to Maui.Graphics in ScottPlot 5 will be a pretty big shake-up, so it may not be worth optimizing ScottPlot 4 at this time. BTW you might get a kick out of #1561 - It's barebones but the WinForms app is the most developed. I'm experimenting with architecture. After a few years getting to know the pain points of this library, I'm leaning toward minimizing state stored in the plot module itself. Types like PlotView mouseDownView = plt.GetAxisLimits();
PlotView currentView = mouseDownView.WithPan(mouseDownPixel, mouseNowPixel);
Bitmap bmp = plt.Render(currentView);None of this is set in stone (I'm still waiting for Maui.Graphics to mature - it's getting there though), but it's interesting to consider after working with this library and having a good understanding of its roughest edges. |
|
Great work as always @bclehmann, thanks so much for this PR! I'll merge this now and release this weekend.
EDIT: I'll put this in now real quick, then merge |
No worries! It'll be a few hours before I publish the next package, so this fix will make it in
My trick is to avoid calling |


New Contributors:
Please review CONTRIBUTING.md
Hacktoberfest Participants:
Check-out the Hacktoberfest 2021 page
Purpose:

#1466