From cab22f2dc3c5f41b5163f74cbb233e390edff6ff Mon Sep 17 00:00:00 2001 From: "B. Stack" Date: Tue, 11 Oct 2022 11:16:39 -0400 Subject: add upstream 11.26 --- wx+/graph.cpp | 2 +- wx+/image_resources.cpp | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'wx+') diff --git a/wx+/graph.cpp b/wx+/graph.cpp index f9094386..bee38e36 100644 --- a/wx+/graph.cpp +++ b/wx+/graph.cpp @@ -730,7 +730,7 @@ void Graph2D::render(wxDC& dc) const //unlike wxDC::DrawRectangle() which just widens inner area! wxDCPenChanger dummy (dc, wxPen(it->second.fillColor, 1 /*[!] width*/)); wxDCBrushChanger dummy2(dc, it->second.fillColor); - dc.DrawPolygon(static_cast(points.size()), &points[0]); + dc.DrawPolygon(static_cast(points.size()), points.data()); } //2. draw all currently set mouse selections (including active selection) diff --git a/wx+/image_resources.cpp b/wx+/image_resources.cpp index 58ae4d25..667b5912 100644 --- a/wx+/image_resources.cpp +++ b/wx+/image_resources.cpp @@ -35,8 +35,8 @@ ImageHolder xbrzScale(int width, int height, const unsigned char* imageRgb, cons //get rid of allocation and buffer std::vector<> at thread-level? => no discernable perf improvement std::vector buf(hqWidth * hqHeight + width * height); - uint32_t* const argbSrc = &buf[0] + hqWidth * hqHeight; - uint32_t* const xbrTrg = &buf[0]; + uint32_t* const argbSrc = buf.data() + hqWidth * hqHeight; + uint32_t* const xbrTrg = buf.data(); //convert RGB (RGB byte order) to ARGB (BGRA byte order) { -- cgit