I am trying to figure out what to do when an image I upload to my database is smaller than my max height/width that I have setup for resize on upload.
For example, I have my resize utlity resizing all images to be no larger than 1000 X 1200 pixels and this works great with RadBinary because it "fits" them into my various objects (thumbnail, full size, screen size, etc) at my specificied sizes (for example full size = 500 pixels width). But my problem is sometimes I am supplied with photos that have already been resized to dimensions which are smaller than the ones I have setup for my project (for example I might be supplied with a 300 x 400 image). This causes the image to be streched when I am using radbinary on my page because I have my sizes preset to 500 width.
I would like to know if there is a way to detect the image size from the database, then see if it is smaller than my presets (500 px), if so, then it would need to show the image in its largest format size and if not, show it in my preset size format.
I found this article, but it is referring to using it in the grid, but I am not, I just have the files on my page.
http://www.telerik.com/community/forums/aspnet-ajax/binary-image/change-image-size-different-for-landscape-portrait.aspx
Thanks
For example, I have my resize utlity resizing all images to be no larger than 1000 X 1200 pixels and this works great with RadBinary because it "fits" them into my various objects (thumbnail, full size, screen size, etc) at my specificied sizes (for example full size = 500 pixels width). But my problem is sometimes I am supplied with photos that have already been resized to dimensions which are smaller than the ones I have setup for my project (for example I might be supplied with a 300 x 400 image). This causes the image to be streched when I am using radbinary on my page because I have my sizes preset to 500 width.
I would like to know if there is a way to detect the image size from the database, then see if it is smaller than my presets (500 px), if so, then it would need to show the image in its largest format size and if not, show it in my preset size format.
I found this article, but it is referring to using it in the grid, but I am not, I just have the files on my page.
http://www.telerik.com/community/forums/aspnet-ajax/binary-image/change-image-size-different-for-landscape-portrait.aspx
Thanks