And there's another annoyance I got poked for:

Image texture "Filter size" was not well usable for making the
appearance soft filtered, this because it multiplied the sample 
values, and such values could be extreme small.

Added next to "Filter" buton a new "Min" option, which enforces
a filter size to be a minimum of 'filter' pixels in size.
This commit is contained in:
2007-12-28 18:58:40 +00:00
parent 1c02a5f620
commit c3ecba1d65
3 changed files with 13 additions and 2 deletions

View File

@@ -702,6 +702,15 @@ int imagewraposa(Tex *tex, Image *ima, ImBuf *ibuf, float *texvec, float *dxt, f
minx= tex->filtersize*(maxx-minx)/2.0f;
miny= tex->filtersize*(maxy-miny)/2.0f;
if(tex->imaflag & TEX_FILTER_MIN) {
/* make sure the filtersize is minimal in pixels (normal, ref map can have miniature pixel dx/dy) */
float addval= (0.5f * tex->filtersize) / (float) MIN2(ibuf->x, ibuf->y);
if(addval > minx)
minx= addval;
if(addval > miny)
miny= addval;
}
if(tex->filtersize!=1.0f) {
dxt[0]*= tex->filtersize;
dxt[1]*= tex->filtersize;