f(x)=√2(sinxcosπ/4+sinπ/4cosx)-2cosx
=sinx+cosx-2cosx
=sinx-cosx
=√2sin(x-π/4)
x∈(0,π)
x-π/4∈(-π/4,3π/4)
f(x)的值域是(-1,√2)