Post Reply 
Two Graphics Problems for the Experts
02-19-2016, 02:44 AM
Post: #1
Two Graphics Problems for the Experts


The following pseudo code does not work!

Do calculation;

Display Image 1;

FREEZE;

Do more calculations;

Display Image 2;

FREEZE;

etc. etc.

The reason is that the first command in "more calculations" terminates the FREEZE command. This is explained in the calculator HELP.
The question is ,therefore, how may the images be displayed for a completely arbitrary length of time ? Inserting WAIT( n ) ; before FREEZE is not acceptable since the pause is not of arbitrary length ,i.e. it would not change for different executions of the program. Clearly some mechanism to dismiss the image must be found , probably by key press or display touch .
The second question is how is an image displayed using the emulator saved to a file on the host machine in an appropriate format
? Windows 10 solution preferred.
I think that both problems are of general interest and look forward to learning how expert programmers would tackle them.

sincerely

John
Find all posts by this user
Quote this message in a reply
02-19-2016, 02:50 AM (This post was last modified: 02-19-2016 04:10 AM by Tim Wessman.)
Post: #2
RE: Two Graphics Problems for the Experts
(02-19-2016 02:44 AM)UncleJohn Wrote:  Inserting WAIT( n ) ; before FREEZE is not acceptable since the pause is not of arbitrary length ,i.e. it would not change for different executions of the program. Clearly some mechanism to dismiss the image must be found , probably by key press or display touch .

Have you tried WAIT(-1)? Check the on-calc help for the wait command.

Quote: The second question is how is an image displayed using the emulator saved to a file on the host machine in an appropriate format

If you mean an automated method, you could do

HFiles("filename.png"):=G0

An you'll end up with a png in your main emulator working directory...

[EDIT]

I meant AFiles not HFiles (there is no such command). Your png will end up in the application directory.

TW

Although I work for the HP calculator group, the views and opinions I post here are my own.
Find all posts by this user
Quote this message in a reply
Post Reply 




User(s) browsing this thread: 1 Guest(s)