From 70186149b931a49f1eb599d2f207fdc3d3048388 Mon Sep 17 00:00:00 2001 From: Anton Khirnov Date: Thu, 27 Dec 2018 16:26:29 +0100 Subject: Add threading support through libthreadpool. --- mg2d.h | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'mg2d.h') diff --git a/mg2d.h b/mg2d.h index 2682918..c487215 100644 --- a/mg2d.h +++ b/mg2d.h @@ -260,6 +260,13 @@ typedef struct MG2DContext { * Distance between neighbouring gridpoints along coord1. */ ptrdiff_t diff_coeffs_stride; + + /** + * Number of threads to use for processing. + * + * Set to 0 to autodetect. Defaults to 1. + */ + unsigned int nb_threads; } MG2DContext; /** -- cgit v1.2.3