#NEWLINE# def testOnePixelBlur( self ) : #NEWLINE# #INDENT# constant = GafferImage . Constant ( ) #NEWLINE# constant [ 'color' ] . setValue ( IECore . Color4f ( 1 ) ) #NEWLINE# crop = GafferImage . Crop ( ) #NEWLINE# crop [ 'in' ] . setInput ( constant [ 'out' ] ) #NEWLINE# crop [ 'area' ] . setValue ( IECore . Box2i ( IECore . V2i ( 10 ) , IECore . V2i ( 11 ) ) ) #NEWLINE# crop [ 'affectDisplayWindow' ] . setValue ( False ) #NEWLINE# blur = GafferImage . Blur ( ) #NEWLINE# blur [ 'in' ] . setInput ( crop [ 'out' ] ) #NEWLINE# blur [ 'radius' ] . setValue ( IECore . V2f ( 1 ) ) #NEWLINE# blur [ 'expandDataWindow' ] . setValue ( True ) #NEWLINE# sampler = GafferImage . Sampler ( blur [ 'out' ] , 'R' , IECore . Box2i ( IECore . V2i ( 0 ) , IECore . V2i ( 20 ) ) ) #NEWLINE# self . assertGreater ( sampler . sample ( 10 , 10 ) , sampler . sample ( 11 , 10 ) ) #NEWLINE# self . assertGreater ( sampler . sample ( 11 , 10 ) , sampler . sample ( 11 , 11 ) ) #NEWLINE# self . assertGreater ( sampler . sample ( 11 , 11 ) , 0 ) #NEWLINE# self . assertEqual ( sampler . sample ( 11 , 10 ) , sampler . sample ( 9 , 10 ) ) #NEWLINE# self . assertEqual ( sampler . sample ( 10 , 11 ) , sampler . sample ( 10 , 9 ) ) #NEWLINE# self . assertEqual ( sampler . sample ( 10 , 11 ) , sampler . sample ( 10 , 9 ) ) #NEWLINE# self . assertEqual ( sampler . sample ( 9 , 9 ) , sampler . sample ( 11 , 9 ) ) #NEWLINE# self . assertEqual ( sampler . sample ( 9 , 9 ) , sampler . sample ( 11 , 11 ) ) #NEWLINE# self . assertEqual ( sampler . sample ( 9 , 9 ) , sampler . sample ( 9 , 11 ) )