cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
  • DownloadSemiconductor Toolkit: Tools to create wafer maps, add wafer geometry to graphics, explore die defects & compare wafers.
  • Discovery Summit 2026: Early User Edition - September 23-24.Register. It's free.
  • See how to design an experiment, explore factor-response relationships, assess tradeoffs, and ID best settings. Register for Sep. 11 Mastering JMP.

Discussions

Solve problems, and share tips and tricks with other JMP users.
Choose Language Hide Translation Bar
TWE
TWE
Level IV

Image rotation

Hi,

I cannot rotate an image. The script in the "Scripting Index" is also not rotating the image. 

Names Default To Here( 1 );
New Window( "Example", pb = Picture Box( Open( "$SAMPLE_IMAGES/tile.jpg", jpg ) ) );
image = pb << Get Image();
image << rotate left;

 

2 ACCEPTED SOLUTIONS

Accepted Solutions
Craige_Hales
Super User

Re: Image rotation

Cool. There is something broken about the scripting index example though... (edit: sent note to dev team)

Before I saw Jim's answer, I modified the example a different way:

Use <<rotate(-90) and then show the new image in a separate window.Use <<rotate(-90) and then show the new image in a separate window.

Craige

View solution in original post

andersonmj2
Level IV

Re: Image rotation

I agree that there is an issue with the Scripting Index - the way I look at the code is that in one you get a handle to the Picture Box object and in the other you get a handle to the image. So rotating the image doesn't matter until you then display it as you showed. 

If you put a "Wait (1);" in @txnelson code before the "pb << rotate left;" line, you will see the image displayed and then rotated in place.

Thanks for your answers - not something I have tripped over yet, but would have soon!

View solution in original post

3 REPLIES 3
txnelson
Super User

Re: Image rotation

Try this

Names Default To Here( 1 );
New Window( "Example", pb = Picture Box( Open( "$SAMPLE_IMAGES/tile.jpg", jpg ) ) );
pb << rotate left;

txnelson_0-1674559046975.pngtxnelson_0-1674559046975.png

 

Jim
Craige_Hales
Super User

Re: Image rotation

Cool. There is something broken about the scripting index example though... (edit: sent note to dev team)

Before I saw Jim's answer, I modified the example a different way:

Use <<rotate(-90) and then show the new image in a separate window.Use <<rotate(-90) and then show the new image in a separate window.

Craige
andersonmj2
Level IV

Re: Image rotation

I agree that there is an issue with the Scripting Index - the way I look at the code is that in one you get a handle to the Picture Box object and in the other you get a handle to the image. So rotating the image doesn't matter until you then display it as you showed. 

If you put a "Wait (1);" in @txnelson code before the "pb << rotate left;" line, you will see the image displayed and then rotated in place.

Thanks for your answers - not something I have tripped over yet, but would have soon!

Recommended Articles