Posted By

yuconner on 08/19/07


Tagged

Maths


Versions (?)

min/max clip


 / Published in: Python
 

bounding values

  1. newbyte = min( max(newbyte,a_min), a_max )
  2.  
  3. #or
  4.  
  5. newbyte.clip( min=a_min, max=a_max )

Report this snippet  

You need to login to post a comment.