Forums > MaxMSP

Re-size fpic?

Mar 17 2014 | 9:10 am

Hi All,

I’m trying to display an image (jpeg) fullscreen. From a previous thread I understand that I can get the screen size from [screensize] and use that to re-size a [fpic], however, I can’t work out what message to send [fpic] to resize it. Please can someone tell me (or, even better, post an example)?

Second, is it possible to scale the image rather than have it stretched-to-fit in [fpic]

Many thanks in advance for your help.



Mar 17 2014 | 9:28 pm

grab values:

[getattr] gets the current xy position of fpic.

[screensize] gets screen dimensions.

sending a [window getsize] message to [thispatcher] returns the current window size.


Use [window size $1 $2 $3 $4, window exec] to [thispatcher] to change the window size.

send [patching_rect $1 $2 $3 $4] or [presentation_rect $1 $2 $3 $4] message to [fpic] to change the pic location and size. (The first two values are xy position and the last two are the size dimensions).

To scale your pic proportionally, multiply x, y by the same number. You can use [vexpr $f1*$f2 @scalarmode 1] with the x and y dimension values sent as list to the left inlet and a float scaling factor sent the right inlet.

Mar 18 2014 | 7:35 am

Thanks for your help, Metamax! Really appreciated. I’m working with these parameters now, looking good so far.

All the best,


Viewing 3 posts - 1 through 3 (of 3 total)

Forums > MaxMSP