How set wallpaper in flash as3? - actionscript-3

Who can help me to make the photo On the desktop ..For example, to save the image in the stage in Flash and make it a background in desktop(in flash function to make an image as wallpaper)or background in phone Using the button thanks..

It's not possible to set an image in flash to become your desktops wall paper. You can adjust the images size and parameters via flash and export, then you will have to set it as our desktop wallpaper manually.

For the desktop platform, you can encode the image into an OS-readable format (PNG, JPG, others depend on OS) and call FileReference.save() with the encoded ByteArray. This will invoke the OS-specific dialogue of "Save as" where the user will have to input the proper name for the file with its extension (if OS requires an extension), so you will have to hint the user of what type of file he will receive. For this, you can name your button "Save as PNG", for example. A code example is here in this question.

Related

How get a GIF from .SWF file with AS3 and Binary?

I have a SWF file that should display an animated image. This file contains pictures, a file ActionScript 3.0 and several Binary files.
My question is, how get a GIF of the result of this SWF file ?
Thanks in advance.
To make a GIF Image in Flash, go to Publish Settings in properties, and click the box next to GIF Image then click publish.
Also make sure that it works by uploading it online.
Hope this helps

Save picture of current screen to disk AS3

I want to add a button to my flash game (AS3) and on click it saves a picture of the current users whole screen and saves it to pictures/disk automatically, but I don't know how to do that, I know how to add the button to the UI and add a click event and all that, just need to know how to make it save a picture of the current screen to disk (doesn't have to be just the flash screen, can be the WHOLE screen of the users pc, either way works!)
I was on my way writing you the answer but I found this post have a better explaination: Is it possible to capture the screen and save the image in actionscript 3?
"Yes, it's possible.
Draw some display object to a BitmapData (the stage, for example) and crop it if neccesary (the second param of BitmapData::draw will help you out here).
Then, convert the raw pixel data to JPEG or PNG using some encoder. I'm sure up to this point, this is what those tutorials will explain you how to do.
Now, the third step is different but simple enough. Instead of sending the image data to a server side script, use a FileReference object. Since Flash Player 10, it has a method called save, that prompts the user to save a file locally.
Since this is a desktop app, you could also make it an AIR app. This will give more direct access to the file system and other features, in case you need them."

How to detect the color of an image using AS3 and adobe air?

I'm having a hard time finding any data on how to detect the color of an image taken from a phone's camera using adobe air. The idea is that the user takes an image and then the app (that uses this code) detects the color of the item the user has photographed by placing a cursor on top of it.
So does someone please tell me how is this attainable in adobe air and action script 3.
many thanks in advance!!!!
You can use getPixel or getPixel32 from BitmapData() enter link description here
Than you can convert it to HEX if you wish.

Create SWF video of images through Adobe Flex

I don't know whether it's the right place to put this up. But I've been trying from past 12 hours and haven't found anything related.
I'm creating a Adobe AIR project (which'll run on desktop), it'll ask for image locations on the local pc.
After the user is done selecting images. I want to output a SWF video (slideshow) of the selected images.
How to do the second step. Please guide. I want to create an output file (SWF) from my AIR Flex Desktop Application.
Check out https://github.com/claus/as3swf to compile SWFs at runtime...
This individual seems to have had a similar issue AS3 to Generate Dynamic SWF?
You can try following options from SWFtools
JPEG2SWF Takes one or more JPEG pictures and generates a SWF slideshow from them. Supports motion estimation compression (h.263) for better compression of video sequences.
PNG2SWF Like JPEG2SWF, only for PNGs.
GIF2SWF Converts GIFs to SWF. Also able to handle animated gifs.
Here is what I did :
Install the as3 compiler (mxmlc)
Run the command mxmlc.exe sample.as3 using NativeProcess

swf to image on the website?

i want to convert a swf to image on my website. a user makes some changes on the stage and if he press a button "get image link", the swf stage will be converted to an image and its image link will appear within a box. like imageshack.. so user can use it in forums as image. how can i do this? i even dont know it is about flash or html...
Have a good read of Henry Jones - Using the AS3 Jpeg Encoder. He explains exactly what you need, plus some!
You basically what to use the BitmapData class to convert you displayobject into image data. Then you can use JPGEncoder from AS3 Core Lib, to encode that data into a JPEG. Then with a bit of serverside code you can send that JPEG to that server.