Multithreaded image processing in C++

后端 未结 16 715
既然无缘
既然无缘 2020-12-29 12:16

I am working on a program which manipulates images of different sizes. Many of these manipulations read pixel data from an input and write to a separate output (e.g. blur).

16条回答
  •  别那么骄傲
    2020-12-29 12:38

    Maybe write your own tiny library which implements a few standard threading functions using #ifdef's for every platform? There really isn't much to it, and that would reduce the executable size way more than any library you could use.

    Update: And for work distribution - split your image into pieces and give each thread a piece. So that when it's done with the piece, it's done. This way you avoid implementing job queues that will further increase your executable's size.

提交回复
热议问题