Services & Resources / Wolfram Forums / MathGroup Archive
-----

MathGroup Archive 2009

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: How to stretch a image

  • To: mathgroup at smc.vnet.net
  • Subject: [mg96551] Re: How to stretch a image
  • From: Jens-Peer Kuska <kuska at informatik.uni-leipzig.de>
  • Date: Mon, 16 Feb 2009 06:57:20 -0500 (EST)
  • References: <gn8jat$7o0$1@smc.vnet.net>

Hi,

if you don't care about the lausy reconstruction filter

img = Import["http://blog.wolfram.com/images/people/sw.jpg";];

img2 = Rasterize[
   img /. Graphics[Raster[bm_, r_, any___], more1___, ImageSize -> _,
      more2___] :>
     Graphics[Raster[bm, {{0, 0}, {600, 400}}, any], PlotRange -> All,
      AspectRatio -> 1/3, more1, more2, ImageSize -> {600, 200},
      PlotRangePadding -> {0, 0}]]

Regards
   Jens


goodhei8 at gmail.com wrote:
> such as the size of a image is 100 x 100, I want to make it stretch to 
> 200 x 600 (not 1:1). Mathematica give me 200x200 +200x400 blank. I tried 
> Padding and Margins, no working : (
> 
> PS, in Mathematica 6.
> Thanks in advance.
> 


  • Prev by Date: Howto change TraditionalForm Output
  • Next by Date: Re: Length of a held expression
  • Previous by thread: Re: How to stretch a image
  • Next by thread: Re: How to stretch a image