I want to create an effect where I use a quite large image to produce a smaller image with HLSL through a WPF Effect. But it seems that WPF for some reason resizes all input images to the rendered size, which isn't what I want, since it will crop one of my images quite a lot and make my final image look not so good.
This is how I have it set up. I have an image (a video) that is the size of 2592x1944 that is played in a MediaElement. I apply my effect on a Border (or other element) with the size of 800x600 and bind the MediaElement to the effect to be able to send both the surface to render on (the border) and the source to render from (the MediaElement) to the pixel shader.
But the resulting image is very pixelated due to heavy cropping of the source.
Does anyone know if there's a way to get WPF to not crop the pixel shader samples?
I found this blogpost by Greg Schecter that kinda do what I want, but the other way around: http://blogs.msdn.com/b/greg_schechter/archive/2008/09/27/a-more-useful-multi-input-effect.aspx He shrinks an image, but I want to make it bigger I guess. The thing is that he uses an ImageBrush, and I got a VisualBrush since I use UIElements and not images. Don't know if there's a way of doing the stuff he does on a VisualBrush.