You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I would like to use PIL to perform an affine warp on an image, but I want to specify a custom fill value for undefined pixels. The transform function seems to have a fill=1 argument, but it is undocumented and looking further in the code it seems to be unused.
Is there any way to get a custom fill value in an affine transform?
The text was updated successfully, but these errors were encountered:
radarhere
changed the title
Affine transformation fill parameter seems to do nothing.
Affine transformation fill parameter seems to do nothing
Nov 7, 2017
Internally, in _imaging.c, the fill parameter is passed in, but subsequent calls into the core transform routines set it to 1. In those routines, the fill parameter is a flag for memset(0) on the non-affected locations. In theory, it should be possible to set this fill to some pixel value.
I would like to use PIL to perform an affine warp on an image, but I want to specify a custom fill value for undefined pixels. The
transform
function seems to have afill=1
argument, but it is undocumented and looking further in the code it seems to be unused.Is there any way to get a custom fill value in an affine transform?
The text was updated successfully, but these errors were encountered: