Forums > Jitter

jit.window message: controlling the size of an image

February 12, 2007 | 12:37 pm

max v2;
#N vpatcher 348 94 948 494;
#P origin 61 168;
#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P newex 552 318 33 9109513 sel 32;
#P message 489 343 68 9109513 fullscreen $1;
#P toggle 471 343 15 0;
#P newex 514 318 35 9109513 sel 27;
#P newex 472 318 40 9109513 key;
#P newex 327 366 73 9109513 jit.window demo;
#P toggle 327 285 15 0;
#P message 377 312 60 9109513 read test.jpg;
#P window setfont "Sans Serif" 14.;
#P newex 327 338 131 9109518 jit.qt.movie 800 600;
#P window setfont "Sans Serif" 9.;
#P newex 327 313 45 9109513 metro 20;
#P connect 3 0 0 0;
#P connect 2 0 1 0;
#P connect 0 0 1 0;
#P connect 8 0 4 0;
#P connect 1 0 4 0;
#P fasten 6 0 7 0 519 340 476 340;
#P fasten 7 0 8 0 476 365 494 365;
#P fasten 5 0 6 0 477 341 464 341 464 314 519 314;
#P connect 5 0 9 0;
#P pop;

This is part of a patch I’m using to display .jpg files in jit.window. My problem is that when I use full screen mode, the .jpg file is stretched over the entire screen, even if the jpg has small dimensions. Is there a way to display it as its actual size or to control the size?


February 12, 2007 | 12:53 pm

Hi Bart,

There are several ways. Have a look at the tutorial
14jMatrixPositioning. jit.mxform2d, jit.resamp the drawpict message
to jit.lcd or jit.gl.videoplane.

falk

Am 12.02.2007 um 13:37 schrieb Bart:

> max v2;
> #N vpatcher 348 94 948 494;
> #P origin 61 168;
> #P window setfont "Sans Serif" 9.;
> #P window linecount 1;
> #P newex 552 318 33 9109513 sel 32;
> #P message 489 343 68 9109513 fullscreen $1;
> #P toggle 471 343 15 0;
> #P newex 514 318 35 9109513 sel 27;
> #P newex 472 318 40 9109513 key;
> #P newex 327 366 73 9109513 jit.window demo;
> #P toggle 327 285 15 0;
> #P message 377 312 60 9109513 read test.jpg;
> #P window setfont "Sans Serif" 14.;
> #P newex 327 338 131 9109518 jit.qt.movie 800 600;
> #P window setfont "Sans Serif" 9.;
> #P newex 327 313 45 9109513 metro 20;
> #P connect 3 0 0 0;
> #P connect 2 0 1 0;
> #P connect 0 0 1 0;
> #P connect 8 0 4 0;
> #P connect 1 0 4 0;
> #P fasten 6 0 7 0 519 340 476 340;
> #P fasten 7 0 8 0 476 365 494 365;
> #P fasten 5 0 6 0 477 341 464 341 464 314 519 314;
> #P connect 5 0 9 0;
> #P pop;


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