ActionScript 3.0 :: Use ByteArray Or Something Else?

Dec 12, 2010

at the current status of my project i must write an application (With AIR or ZINC) who its job is:

1st-getting some files from user. 2nd-modify them with an algorithm (encryption or encoding or changing byteArray) to simply corrupt the file and make it impossible for other applications to read the corrupted file!

[Code]...

View 4 Replies


Similar Posts:


Actionscript 3 :: Introduce A Sound From The Library To A ByteArray (and Then Play That ByteArray)?

Feb 16, 2011

I am working on a game, made with Flash (using AS3) The game has a fast ball and when this ball hits an object it has to make a sound... but the sound starts with delay (so the ball is far away when the sound is played).This sound is edited by me and it hasn't got any silences at the beginning.The method i'm currently using is the simplest one:

public var sonidoPuntos1:sonidopunto1 = new sonidopunto1()

and then...

sonidoPuntos1.play()

I am trying to introduce the file into a ByteArray and then playing it from there...

View 2 Replies

ActionScript 3.0 :: Convert Wav ByteArray To Mp3 ByteArray?

Mar 28, 2011

I know its a true Pain but does anyone know any way to convert wav ByteArray to mp3 ByteArray.

View 1 Replies

Send A ByteArray To FMS?

Sep 23, 2011

Who knows how to send a ByteArray to FMS?

View 1 Replies

IDE :: Creating A Swf With ByteArray

Jul 14, 2009

I am trying to create a new swf with AIR and Flash CS3. All I want to do is push a button and have a new swf saved to the desktop with a line of actionscript in it. The actionscript can be anything stop(); - for instance.I have been messing around with ByteArray and I can save an image to a swf but I can't find any information on what I want to do.

View 2 Replies

ActionScript 3.0 :: UTF-16 Representation In A ByteArray REgards

Jan 17, 2010

Is there a way to write a UTF-16 string into a ByteArray in Flash/AS3? Basically I have a string (var test:String="allan"; for example) and I would like to write that into a ByteArray with UTF-16LE encoding. In this case it would be "61 00 6C 00 6C 00 61 00 6E 00".
 
I've tried using utf16le.writeMultiByte( clipText, "utf-16" ); but it just comes out with what appears to be UTF8 (or just straight ASCII given the test string).
 
The use case is to save a UTF-16LE file using FileReference.save(), which I understand I can do by passing it a ByteArray with the correct character encoding in it. Passing just a string saves as UTF-8. Hence the need to convert and store into a UTF-16LE representation in a ByteArray.

View 13 Replies

Actionscript 3 :: BitmapData To ByteArray?

Jul 28, 2010

I am trying to serialize a Bitmap to store in an XML file. My plan is to turn the BitmapData into a byteArray, but I haven't been able to fine an example of this.

View 1 Replies

Xml :: Loading Bytearray Into XML Object?

Oct 14, 2010

I get Index out of bounds when trying to readObject on my Byte array into the XML object.

private var fr:FileReference;
private var data:ByteArray = new ByteArray();
[Bindable]
private var dataXML:XML = new XML();[code]....

The Byte array is created by loading a file using FileReference

View 2 Replies

Flex - SWF To Bytearray From A PHP Script?

Nov 7, 2010

i'm using AMFPHP to stream content from my server to my Flex application, since Flash is a clientside technology i would like to make it harder for people to grab protected files, so i created a system that streams swf file to another flash player, i've done all the testing on URL stream, now i want to pass the swf file to the player as bytearray .. since i think it's safer and harder to break and in the future i even might do some encryption of my own if i became more familiar with bytes and bits .. anyways is my method the best one? (SWF to ByteArray?) or is there a better one? if the bytearray method is the best, i am facing a problem in outputing the swf file in the right format, i'm using a very primitive method .

[Code]...

View 1 Replies

Flex - Loading Swf With Bytearray In AIR?

Jan 25, 2011

We have requirement with the AIR application which loads the flex generated swf which inturn loads the flash generated swf using SWFLoader. This is not working as desired.This gives the following error: SecurityError: Error #3226: Cannot import a SWF file when LoaderContext.allowCodeImport is false.

[Code]...

View 2 Replies

Php :: Flash - Sending ByteArray Through PHP?

Mar 22, 2011

The BLOB field (pic) is turning out as 0 Bytes when trying to send ByteArray through as3 to PHP, so i assume the PHP script or the HTTP_RAW_POST_DATA isn't working.I think the Flash part is working, I have set a trace() to see if the bitmapdata is coming through and it seems it is, so I'm assuming its my php side.3

private function export():void
{
var bmd:BitmapData = new BitmapData(600, 290);

[code].....

View 2 Replies

ActionScript 3.0 :: Mp3 Creation Using Bytearray?

Feb 2, 2010

I want to make a flash application in which i will load 3-4 different mp3 files of different instrumental music. After loading it I want play all files. Further I want to save or create a merged mp3, from all mp3s sound files in a single mp3 file.

Is it possible to convert different mp3 sound track in to different ByteArray and later using any other technology like PHP or C# can we merge all byteArray in a single byteArray to create a single mp3 file.
So that we can listen all instrument playing in a single mp3 file.

View 8 Replies

ActionScript 3.0 :: Load Swf As Both ByteArray And Swf?

Mar 31, 2011

I have a load of information in a swf that I'm loading at runtime. From that swf I need to get raw vector data out of some MovieClips, and other MovieClips I need to instantiate and put on the stage.Currently I can get at the vector data by loading the swf as a ByteArray using a URLLoader and parsing it with a bit of help from as3swf.

However, if I want to instantiate one of the MovieClips directly I would usually load it with a Loader and get at the MovieClip via loaderInfo.applicationDomain.My question is: can I either load the swf as a ByteArray with URLLoader and somehow instantiate MovieClips from that, or can I load the swf as a DisplayObject using a Loader, get the MovieClips and then convert the swf to a ByteArray before giving it to as3swf for parsing?

View 2 Replies

ActionScript 3.0 :: Does Recording From Mic Into ByteArray Usually Lag?

Mar 11, 2012

Summary: is there usually a lag when recording audio from the mic? I am using Thibault Imbert 'micrecorder' library on google code to record audio from the mic into a ByteArray. I am instructing my users to speak two seconds after the recorder starts. I know its two seconds after the recorder starts, rather than two seconds after the user presses the record button, because micrecorder issues time adjusted events of the recorder progress.

When I get the finished ByteArray the actual floats inside it that record the user speaking seem to be 2.5 seconds worth of samples into the ByteArray! So my question, as this is the first time I have recorded audio, is it usual to find a lag like this when recording? Or do you think I am getting something wrong with my math when indexing into the ByteArray?

View 0 Replies

ActionScript 2.0 :: Load An FLV Into A ByteArray?

Oct 26, 2006

Any way to load an FLV into a ByteArray, modify it (maybe add a water mark) and pass it to the Video Object for display?

View 2 Replies

ActionScript 3.0 :: ByteArray Reading Long Value?

Dec 28, 2011

I have a java server sending the time with:long time = System.currentTimeMillis();I put this in a packet. It takes up the first 8 bytes of the packet and send it to the as3 client.Then in as3 I read the packet but since there is no readLong function with ByteArray, I can only think of reading it with readDouble to read the first 8 bytes of the packet. I'm not sure if this is the right way to do it.

I compared it with the time from AS3's function: Date().time;The time I get from AS3's Date().time is different than the time I receive from reading the packet with the time sent from the java server.I'm not sure if I'm using the wrong time functions or reading the packet wrong.

View 1 Replies

ActionScript 1/2 :: How To Convert Bytearray To Video

Dec 24, 2006

I want to convert a ByteArray wich contains a .flv file read through a socket connection to a video playable object and play it, or attach it somehow to the netstrem as its source. Why this ? I'm trying to write an app using AS 3.0 that connects two swf clients to each other directly without a server (after they know of each other) and allow them to exchange video sequences. So the reverse way video -> bytearray -> network -> reciever ->video would be of interest aswell.

View 5 Replies

ActionScript 3.0 :: Limit To ByteArray Length?

Apr 16, 2009

My Flash movie has connected to a server via Socket. The server has sent some data over the Socket connection. This data consists of a 4-byte message header which describes the length of the incoming message and then the message itself. In this particular case, my message has a length of 500040 bytes.

My code receives the first installment of this long socket message in a block of 4,380 bytes. I know this because of trace statements in my socketDataHandler function. It peels off the 4 bytes at the beginning and interprets them to get the incoming message length of 500040. The remaining 4376 bytes go into a ByteArray var (a property of my class) called buffer. As more blocks of data arrive, the socketDataHandler function is repeatedly triggered and the extra blocks are concatenated into the buffer.

[Code]...

View 2 Replies

ActionScript 3.0 :: Cloning An Extended ByteArray?

May 20, 2009

I've extended the ByteArray class, like this:[RemoteClass(alias="MyByteArray")]public class MyByteArray extends ByteArray {}and cloned an instance of this class using ByteArray#readObject()/writeObject(). However, for some reason, the cloned object is an instance of ByteArray rather than MyByteArray. This

is illustrated in the following example:
registerClassAlias("MyByteArray", MyByteArray);var b1:MyByteArray = new MyByteArray();var tmp:ByteArray = new ByteArray();tmp.writeObject(b1);  tmp.position =

[code].....

View 5 Replies

ActionScript 3.0 :: Microphone Bytearray Mix And Replay?

Sep 20, 2011

I have an application with microphone record and i mix another sound from song. For this step is ok i can save to my desktop and the mix is good.But i would like to play my mix from bytearray.The sound is very slow....... and not same that my file save,My code:

var epos:Number=0
//ByteArray in which the microphone sound data is stored
var soundBytes:ByteArray = new ByteArray();[code].......

View 2 Replies

ActionScript 3.0 :: Load A ByteArray FLV In OSMF?

Oct 21, 2011

I'm working on a local application ( it's not a website or nothing related ) and I have various FLVs with a very simple encryptation method (just like adding 10 at each byte). I can load/play them using NetStream.appendBytes() after my decrypt, but that happens only after I read all video data. What I really need is to stream those videos from a remote url, and decrypting while receiving data, using a OSMF player that I already have.
 
This is my current code just to play my decoded FLV byte array
 
private function playBytes(bytes:ByteArray):void
{
// detecting it's header
if (bytes.readUTFBytes(3) != "FLV")

[Code].....

View 3 Replies

Flex :: Core ByteArray Image?

Sep 6, 2009

var myFile:File = new File("./test.jpg");
var myFileStream1:FileStream = new FileStream();
myFileStream1.open(myFile, FileMode.READ);[code].....

now how can i add byte variable to the canvas ? for example

var canvas:Canvas = new Canvas();
canvas.addChild(byte);

is it possible to add ByteArray to the canvas?

View 2 Replies

Ruby :: Image/ByteArray To SVG Conversion?

Nov 12, 2009

I am wondering if it is possible to get a url to some image on google, say a square (jpg/png/gif), and process it into an SVG. Is this possible?

Right now I'm getting ByteArray data in Actionscript by making a URLRequest('image/on/google'), with dataFormat="binary". I don't think Actionscript could handle/do it, but maybe it could. I'm also good with Ruby, so perhaps is this possible with Ruby?

If so, any sample code/libraries to get started?

I guess another way to ask it is, how do I convert a Bitmap to a set of Vector Paths like Adobe Illustrator does?

View 3 Replies

Actionscript 3 :: Can't Deserialize Object From ByteArray

Feb 10, 2010

I am trying to serialize & deserialize Vector. using ByteArray..[code]No matter what I do, I keep having this error: RangeError: Error #2006: The supplied index is out of bounds. at flash.utils::ByteArray/readObject()

View 3 Replies

Save ByteArray To HardDrive From Flash Swf?

Mar 13, 2010

How to save ByteArray to HardDrive from Flash swf?

So... I have a generated if flash ByteArray Now I want to save it to Hard Drive.

View 2 Replies

Flex :: How To Turn Bytearray Into IList

May 30, 2010

How to turn Array (like Camera.names) into IList (for for ex MXML s:DropDownList

<s:DropDownList x="113" y="121" selectedIndex="0" dataProvider="{Camera.names}"></s:DropDownList>
)?

[code]....

View 1 Replies

Java :: How To Convert Object To ByteArray

Jun 25, 2010

The coding language is Java.I have a ByteArray embedded in ActionScriptObject.(Smartfox Server)I want to convert it into ByteArray.The idea is to save it as an image.This a sequel to the post --> Convert Byte Array from Action Script to Image in Java and save it

View 2 Replies

Actionscript 3 :: Save ByteArray To Mp3 File?

Jul 27, 2010

Well, i am recording the voice from heaphone and the sound data is stored in ByteArray at runtime, now can i stored as mp3 ?i want to save as mp3 file on the client system.. For that, i think i have to use air application..

View 1 Replies

Flex :: Binary String To ByteArray

Aug 3, 2010

I have an array of objects. Each object has 3 integer fields and 2 binary fields.I've utf encoded the binary data and json encoded the array & sent it to Flex client side.On the client side, decoding data, I've got a String representing the binary data (utf decoded).Now, how can I convert this String to ByteArray? Or how can I read each byte of the String?

View 1 Replies

Php :: ByteArray To MySQL From ActionScript 3 -> PHP Via ZendAMF

Dec 1, 2010

I have an ActionScript 3 application that's sending an object to PHP via ZendAMF. The object contains a byteArray from an image.

I have it currently saving the byteArray into a Blob like so:

[code]...

This seems to be working fine and I can see the image in the DB (this is running local and I'm using SequelPRO to view the DB).

The problem is when I'm sending the byteArray back to Flash, Flash reports the byteArray length as 0.

View 1 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved