Quantcast
Channel: Adobe Community : Popular Discussions - DNG SDK
Viewing all articles
Browse latest Browse all 4036

Enable multithreading in DNG SDK

$
0
0

Hi all,

I have to process very fast a large amount of DNG files (couple of thousands) and I have to do this on a regular basis. The processing is a simple conversion to TIF, white balance, and all other parameters are left default. The output is RGB 8 bit per pixel. I have tried libraw but it gets to 2.5 seconds per image and it is a bit slow.

 

Currently I get the following results from dng_validate:

Raw image read time: 0.064 sec
Linearization time: 0.020 sec
Interpolate time: 0.273 sec
Render time: 0.541 sec

This is about 1 second per file.

 

Is it possible to use multiple threads when calling render.Render()? It would be great to reduce the time to 0.3/0.2 seconds for this/

 

Are we talking about features that are not documented/flags to pass when compiling the library/complete re-write since the library was not designed with this in mind?

 

I poked through the code and found that there is some threading in the code:

void dng_area_task::Perform (dng_area_task &task,
                               const dng_rect &area,
                               dng_memory_allocator *allocator,
                               dng_abort_sniffer *sniffer)
    {
   
    dng_point tileSize (task.FindTileSize (area));
       
    task.Start (1, tileSize, allocator, sniffer);
   
    task.ProcessOnThread (0, area, tileSize, sniffer);
           
    task.Finish (1);
   
    }

but it seems that regardless how many threads they are, the tasks are perfromed single threaded.

 

thank you,

 

Calin


Viewing all articles
Browse latest Browse all 4036

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>