src/polygoncache.h

Wed, 08 Jun 2022 19:33:00 +0300

author
Teemu Piippo <teemu@hecknology.net>
date
Wed, 08 Jun 2022 19:33:00 +0300
changeset 204
52e10e8d88cc
parent 200
ca23936b455b
child 206
654661eab7f3
permissions
-rw-r--r--

Concentrate model editing into one coroutine inside main()

#pragma once
#include "main.h"
#include "model.h"
#include "gl/common.h"

struct GetPolygonsContext
{
	ModelId modelId;
	class DocumentManager* documents;
};

struct PolygonCache
{
	std::vector<gl::Polygon> cachedPolygons;
	bool needRecache = true;
};

const std::vector<gl::Polygon>& getCachedPolygons(
	PolygonCache* cache,
	Model* model,
	class DocumentManager* documents);

mercurial