User Tools

Site Tools


isp:contrast

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
isp:contrast [2019/07/14 02:43]
Igor Yefmov
isp:contrast [2019/07/17 23:45]
Igor Yefmov
Line 16: Line 16:
 <code c++>// pseudo-code <code c++>// pseudo-code
 void contrast(/​*array of pixels*/​image,​ double _cst){ void contrast(/​*array of pixels*/​image,​ double _cst){
-  for(const & pixel: image){+  for(auto & pixel: image){
     pixel.luma = std::​clamp((pixel.luma - 50) * _sct * _sct + 50, 0, 100);     pixel.luma = std::​clamp((pixel.luma - 50) * _sct * _sct + 50, 0, 100);
   }   }
 }</​code>​ }</​code>​
  
/home/adminsub2r/public_html/dokuwiki/data/pages/isp/contrast.txt · Last modified: 2019/07/17 23:45 by Igor Yefmov