Re: snapshot and background problems
So when I do something like set the filename of image Image to filepath that data is 'the text of the image or just 'the image' which backs the image in its original format. When I ask for 'the imagedata of the image' I get four bytes for each pixel in the image: one byte of zeroes, a byte representing red, blue and green. There is also an alphadata which has a byte of alphadata for each pixel in the image. This data is a serialized stream which representing in sequence the data : left top pixel ... right top pixel, left pixel of the second row ... right pixel of second, left pixel of third row ... right bottom pixel. In a sense the imagedata has alphadata information set to zero (no transparency). How do I put the image in an image into a variable or property? Michael On Jun 28, 2010, at 1:53 PM, J. Landman Gay wrote: Scott Rossi wrote: I have no data to suggest that setting the text of an image is any better or worse than the method of putting image-related data into an image. I've only seen references by the programming dudes at RunRev to use the text property, so I do. They're different properties for different purposes. The imagedata is basically just a screen shot and if you set the imagedata of an image object, what you end up with is just a bitmap. All other binary info is lost, including channel data. If you set the imagedata of an image object that isn't exactly the same size as the original screen shot, the image will corrupt and become unrecognizable. The imagedata must match the size of the image object exactly to display properly. (Once it's set correctly, you can then scale it, but it will look terrible.) Setting the text of an image (or just putting an image reference into an image object, it's the same thing) stores all the binary data, including the alpha channel, and the image is scalable and can be manipulated in lots of ways. The size of the image object does not need to match anything in particular, since the engine will scale the data as needed. Imagedata is useful for creating thumbnails, for example, or for reducing the size footprint of an image in the stack when you know you'll never need to change the displayed bitmap. You can reduce the size of the image internally substantially by using imagedata. Setting the text of an image is more useful if you want to retain all the image properties and manipulate it (rotate, scale, etc.) -- Jacqueline Landman Gay | jac...@hyperactivesw.com HyperActive Software | http://www.hyperactivesw.com ___ use-revolution mailing list use-revolution@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-revolution ___ use-revolution mailing list use-revolution@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-revolution
Re: snapshot and background problems
Recently, Michael D Mays wrote: So when I do something like set the filename of image Image to filepath that data is 'the text of the image or just 'the image' which backs the image in its original format. The image data is not part of the stack -- you create a reference to the external image file. This is useful when you have lots of images that don't all need to be loaded in memory at the same time. How do I put the image in an image into a variable or property? Two ways I can think of: 1) import paint from file (filename of img myImageRef) put the text of last img into myVar delete last img 2) export snapshot from rect (rect of img myImageRef) of img myImageRef to myVar as PNG There may be other ways. Regards, Scott Rossi Creative Director Tactile Media, UX Design ___ use-revolution mailing list use-revolution@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-revolution
Re: snapshot and background problems
Thanks Scott. I don't know what is going on. I tried this before and I didn't get anything but trash. This morning when I ran the handler the image became grey. I had been saying 'set the imagedata ...' instead of '...text...'. I tried text and the same nothing changed. So I deleted and dragged a new image into the background ( for the nth time) and ran the handler again and it worked!?? Michael On Jun 27, 2010, at 11:51 PM, tsj wrote: On 28/06/10 1:42 PM, Scott Rossi sc...@tactilemedia.com wrote: Recently, I wrote: export snapshot from rect 0,0,100,100 to someVar as PNG set the text of image myimage to someVar Correction: ___ use-revolution mailing list use-revolution@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-revolution
Re: snapshot and background problems
Recently, Michael D Mays wrote: Thanks Scott. I don't know what is going on. I tried this before and I didn't get anything but trash. This morning when I ran the handler the image became grey. I had been saying 'set the imagedata ...' instead of '...text...'. I tried text and the same nothing changed. So I deleted and dragged a new image into the background ( for the nth time) and ran the handler again and it worked!?? Your image may have been messed up -- I've seen this happen where repeatedly setting image data of an image causes it to stop responding. Setting imageData by itself is OK, but over the last few years, I've taken to setting the text of an image (ironic) to any picture-related data, because doing so sets both image/alpha properties at the same time. This is important to maintain transparency when it comes to PNG images. Setting image/alphaData properties in 2 separate steps is klunky. I have no data to suggest that setting the text of an image is any better or worse than the method of putting image-related data into an image. I've only seen references by the programming dudes at RunRev to use the text property, so I do. Regards, Scott Rossi Creative Director Tactile Media, UX Design ___ use-revolution mailing list use-revolution@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-revolution
Re: snapshot and background problems
Hi, just a thought, as I don 't know your context... Maybe the right time to look at the paintcompression ( Rev dictionary ) my 2 cents Thierry Recently, Michael D Mays wrote: Thanks Scott. I don't know what is going on. I tried this before and I didn't get anything but trash. This morning when I ran the handler the image became grey. I had been saying 'set the imagedata ...' instead of '...text...'. I tried text and the same nothing changed. So I deleted and dragged a new image into the background ( for the nth time) and ran the handler again and it worked!?? Your image may have been messed up -- I've seen this happen where repeatedly setting image data of an image causes it to stop responding. Setting imageData by itself is OK, but over the last few years, I've taken to setting the text of an image (ironic) to any picture-related data, because doing so sets both image/alpha properties at the same time. This is important to maintain transparency when it comes to PNG images. Setting image/alphaData properties in 2 separate steps is klunky. I have no data to suggest that setting the text of an image is any better or worse than the method of putting image-related data into an image. I've only seen references by the programming dudes at RunRev to use the text property, so I do. Regards, Scott Rossi Creative Director Tactile Media, UX Design ___ use-revolution mailing list use-revolution@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-revolution ___ use-revolution mailing list use-revolution@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-revolution
Re: snapshot and background problems
Scott Rossi wrote: I have no data to suggest that setting the text of an image is any better or worse than the method of putting image-related data into an image. I've only seen references by the programming dudes at RunRev to use the text property, so I do. They're different properties for different purposes. The imagedata is basically just a screen shot and if you set the imagedata of an image object, what you end up with is just a bitmap. All other binary info is lost, including channel data. If you set the imagedata of an image object that isn't exactly the same size as the original screen shot, the image will corrupt and become unrecognizable. The imagedata must match the size of the image object exactly to display properly. (Once it's set correctly, you can then scale it, but it will look terrible.) Setting the text of an image (or just putting an image reference into an image object, it's the same thing) stores all the binary data, including the alpha channel, and the image is scalable and can be manipulated in lots of ways. The size of the image object does not need to match anything in particular, since the engine will scale the data as needed. Imagedata is useful for creating thumbnails, for example, or for reducing the size footprint of an image in the stack when you know you'll never need to change the displayed bitmap. You can reduce the size of the image internally substantially by using imagedata. Setting the text of an image is more useful if you want to retain all the image properties and manipulate it (rotate, scale, etc.) -- Jacqueline Landman Gay | jac...@hyperactivesw.com HyperActive Software | http://www.hyperactivesw.com ___ use-revolution mailing list use-revolution@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-revolution
Re: snapshot and background problems
Recently, Jacque Landman Gay wrote: I have no data to suggest that setting the text of an image is any better or worse than the method of putting image-related data into an image. I've only seen references by the programming dudes at RunRev to use the text property, so I do. They're different properties for different purposes. Great recap Jacque, but I was referring to the methods of setting text of an image versus putting image content stored in a variable into an image. As far as I know, both methods accomplish the same result while neither offers any significant benefit over the other. I need increase the alphaData of my comments so they're not so opaque. Regards, Scott Rossi Creative Director Tactile Media, UX Design ___ use-revolution mailing list use-revolution@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-revolution
Re: snapshot and background problems
Scott Rossi wrote: Recently, Jacque Landman Gay wrote: I have no data to suggest that setting the text of an image is any better or worse than the method of putting image-related data into an image. I've only seen references by the programming dudes at RunRev to use the text property, so I do. They're different properties for different purposes. Great recap Jacque, but I was referring to the methods of setting text of an image versus putting image content stored in a variable into an image. As far as I know, both methods accomplish the same result while neither offers any significant benefit over the other. I need increase the alphaData of my comments so they're not so opaque. Oops. It's me that's opaque. I know you knew all that, so I was preaching to myself. Bloviating. Preaching to the choir. Blathering. Talking to hear myself. But me either. I mean, I don't know if there's any difference. I use put more than set just because I'm so used to it and habit is a hard thing to break. Mark Waddingham uses set because he thinks of everything in terms of base syntax and I suspect under the hood that putting an image really sets it. Or at least, that's my theory and I'm sticking to it. -- Jacqueline Landman Gay | jac...@hyperactivesw.com HyperActive Software | http://www.hyperactivesw.com ___ use-revolution mailing list use-revolution@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-revolution
snapshot and background problems
I have a revBrowser and I want to take a snapshot of it and save the image on a card and do this a lot of times for many pages. I can take a snapshot of revBrowser and save the file: export snapshot from rect 0,0,100,100 to aFile.png as png . How do I save a copy of the snapshot to an image on the card? I have tried export snapshot from rect 0,0,100,100 to someVar set the imagedata of image myimage to someVar and I have used the revBrowserSnapshot command also but all I get is garbage in the image. The rect of the snapshot is three times larger than the rect of the image. It seems that if I have an image and a field in a group on a card with the behave as background property checked I can use that group as a template on that card with the create card command. The field has a sharedText property. Does the image have a shredImage property I can turn off. If I can't do I just create a new image on each new card. Thanks, Michael___ use-revolution mailing list use-revolution@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-revolution
Re: snapshot and background problems
Recently, Michael D Mays wrote: I can take a snapshot of revBrowser and save the file: export snapshot from rect 0,0,100,100 to aFile.png as png . How do I save a copy of the snapshot to an image on the card? Try this: export snapshot from rect 0,0,100,100 to someVar as PNG set the text of image myimage to someVar Or this: import snapshot from rect a,b,c,d of this cd Regards, Scott Rossi Creative Director Tactile Media, UX Design ___ use-revolution mailing list use-revolution@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-revolution
Re: snapshot and background problems
Recently, I wrote: export snapshot from rect 0,0,100,100 to someVar as PNG set the text of image myimage to someVar Correction: export snapshot from rect 0,0,100,100 of this cd to someVar as PNG set the text of image myimage to someVar Regards, Scott Rossi Creative Director Tactile Media, UX Design ___ use-revolution mailing list use-revolution@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-revolution
Re: snapshot and background problems
On 28/06/10 1:42 PM, Scott Rossi sc...@tactilemedia.com wrote: Recently, I wrote: export snapshot from rect 0,0,100,100 to someVar as PNG set the text of image myimage to someVar Correction: export snapshot from rect 0,0,100,100 of this cd to someVar as PNG set the text of image myimage to someVar or... put someVar into image myImage Terry... Regards, Scott Rossi Creative Director Tactile Media, UX Design ___ use-revolution mailing list use-revolution@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-revolution ___ use-revolution mailing list use-revolution@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-revolution