From b28a850a8ab4532ee425439446f5b4e01f9471a9 Mon Sep 17 00:00:00 2001 From: Tim Redfern Date: Mon, 18 Sep 2017 22:32:45 +0100 Subject: threading working --- gui/src/chainImageSet.h | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) (limited to 'gui/src/chainImageSet.h') diff --git a/gui/src/chainImageSet.h b/gui/src/chainImageSet.h index 87b1d11..b7bf868 100644 --- a/gui/src/chainImageSet.h +++ b/gui/src/chainImageSet.h @@ -7,6 +7,8 @@ class chainImageSet{ public: chainImageSet(){ + } + void init(){ currentDefaultImageRatio=0.3; filename=""; outputSize=ofPoint(1024,576); @@ -35,11 +37,19 @@ class chainImageSet{ ofPoint outputSize; - std::list images; + std::list > images; float currentDefaultImageRatio; - std::list::iterator selected; + //how to make selected and currentimage work if images is a list of unique_ptr? + //req: + //A: a container for images + //B: a temporary container for images that are loading + //be able to transfer images from B to A + //C: an iterator to A + //be able to loop through C and identify an element which is pointed to by C + + std::list >::iterator selected; ofPoint clickPoint; ofPoint dragPoint; float dragScale; @@ -48,14 +58,14 @@ class chainImageSet{ std::string filename; - chainImage *currentImage; + std::list >::iterator currentImage; float decayFactor; bool additive; float intensity; - std::vector < std::unique_ptr > loadingImages; + std::vector > loadingImages; threadedChainImageLoader loader; }; \ No newline at end of file -- cgit v1.2.3