ActionScript 3.0 :: Drawing Program That Exports The SVG Coordinates To A .txt And Php?
Jan 27, 2009
I've created a drawing program that exports the SVG coordinates to a .txt and php loads the coordinates back in to flash. But is there a way to use the coordinates and have the drawing on the board?
Is there another way to do this instead of using the SVG coordinates?
I have a small flash that I'd like to expand upon, and basically I'm wondering if it's possible to Make a button that lets you erase things on click, rather than clearing the screen.Draw lines of different colours/thicknessHave the Flash output a code for the drawing (similar to Punk-o-Matic 1/2) and be able to put it into the Flash in a text form to have it output the picture. (Thus allowing sharing of pictures).Here's the code.
I have 2 balls, which i connect with a drawn line using the following code.
[Code]....
This code works great except the line I draw has the wrong x coordinates....The line is drawn to the correst y value but the X is at least 300px off? Does it have to do with my anchor point or reg point?
I need a help in AS 3.0. The requirement is, user needs to draw something and take a screenshot or in the PDF format from flash swf by clicking a Save button[Save button will be in the same flash file]. Is it possible in AS 3.0 without any other server-side program?
This is very urgent. Please let me know whether this is possible or not.
I am drawing a set of connected lines in a MC that is created using createEmptyMovieClip. The lines start at (0,0) within the MC and move into the negative x values when the lines move left. The problem I am having is when repositioning the MC. When I tell the MC to move to _x=0 and _y=0, it doesn't move to the stage's (0,0), it still hangs off the left side of the stage. The following image shows the MC positioned to (0,0) (note: the green is the stage):shouldn't the MC containing the drawn lines use its left-most point when being repositioned so that it doesn't hang off the left side of the stage?
I draw a shape with the pen or line tool. If i did not draw it perfectly connecting the dots, i cannot fill it with the paint buck fill tool. How can you tell it to just close the structure
I need help with this drawing example. The problems I'm having are that the coordinate of the line being drawn always have an offset value to the mouseX, mouseY coordinates as intended, and the drawing automatically stops after a while for no reasons at all. I don't know what's wrong.
I have created a paint/drawing program, and I want to be able to add a button to the menu that allows you to open a new page. When you create the new page it creates a tab inside of the application and not just opening a new browser tab. I can do the new page to a new browser tab, but I want to be able to keep it inside the program itself.
I have a project I am working on, it has zero coding most all symbols are graphic because it seems the movie symbols don't export correctly. I export it to swf and it hands 100% of the time when it is at about 80% complete. I have gone back in and optimized tons of it, and it did not change a thing.
I want to make an app that allows the user to add their own content (pics, movie clips, songs) and then the app saves/exports the content as a SWF so that the users can use the exported swf wherever they like. Can this be done? What do I need to look into?
I am importing a video (mp4 format) into Flash and selecting "Load external video with playback component". I am using one of the playback components that goes under the movieWhen I play the movie, everything looks like one, but when I export, the movie is one swf and the component is another swf file.
Im trying to add an exit button onto my program so when its clicked it exits the program completely.. I've tried some of the suggestions on the forums but they arnt working. what I have been using and its not working..
// CLICK to Exit exit_Btn.addEventListener("mouseUp", goExit); function goExit(evt:MouseEvent) { fscommand("quit"); };
I need to program a timer for a typing tutorial program. It needs to go to 5 minutes. When the timer gets to 5 minutes the movie has to go to frame 13 which displays the results of the typing test.
I was trying to convert global coordinates to local coordinates of a UIComplenent in my flex project using below code using below code
var gp:Point = new Point(e.stageX,e.stageY); //global point var lp:Point = uic.globalToLocal(gp); //local point
uic is UIComponent in which I have subclass of Sprite for drawing something I have set the sprite's mouseEnabled and mouseChildren to false to not interrupt the mouse event. above code is within uic's mousemove event where I was tracing the gp and lp gp was giving correct value and suprisingly lp was giving negetive values. when I move the move to the top left corner of uic i expect lp to be 0,0 but it is giving the -width of of uic. I broke my head for hours and ended up finding an alternate by using offsets. Infact my original code was much simpler like this which was same issue
var lp:Point = new Point(e.localX,e.localY);
I am not sure what exactly is causing this problem. the workaround had lot of issues and it creating a mess in my rest of the algorithms.Just now I found even more interesting thing (which is actually weird). for some reason I went and create a new lp2
var lp2:Point = new Point(e.localX,e.localY);
now surprisingly it was giving correct values as expected and I went back and changed the code as
var gp:Point = new Point(e.stageX,e.stageY); //global point var lp:Point = uic.globalToLocal(gp); //local point var lp2:Point = new Point(e.localX,e.localY); var lp2:Point = uic.globalToLocal(gp);
now it is expected to have all the lp, lp2 and lp3 variables to be same but weiredly lp two is giving wrong value and lp2 and lp3 were giving correct. I am suspecting using the variable lp has something to do. I am not sure about that but above proves it so right now I am using lp2.
I was reading the 'Isometric Transformations' tutorial by Danko Kozar and I have a few questions. I understand what all the code does, but not how it does it. First of all, how does the following code work:
transforms x,y,z coordinates into Flash x coordinate xFla = function (x, y, z) { // cartesian coordinates[code].....
I understand that it converts 3d coordinates to 2d coordinates, but I don't understand how. What numbers whould be punched into x, y, and z to acquire certain desired effects?Also, what's the difference between moveTo and lineTo:
red line style(1, "0xFF0000", 100); plot(0, 0, 0); draw(200, 0, 0);
Im making a little app in flash using papervision I want to make a regular movieClip show up in the same place as a papervision object. The coordinates seem like perspective is affecting the number displayed.
Basically I've got a reasonably complex drawing object in a fla and I want to reproduce it in a class definition using the drawing api. However obviously this is a tedious task, so is there some trick or automated method of doing this?
Last time I needed to do this it was a drawing of an arrow and I ended up writing down x,y,width,height values for everything but this one has curves in it which I don't have experience with drawing anyway.
I cannot get this to work. Without the "var drawing", "var drawing being true or false" and the "if statement", it works fine. But I need to add the "var drawing" so that you can only draw if you turn it on by pressing the "draw_btn" button. Note, I do not get an error, the script "apparently" contains no errors. Here is the code:
ActionScript Code: var drawing = false _root.createEmptyMovieClip("myLine", 0);
I've created a drawing tool which allows the user to draw on the canvas, the problem is that if I try to draw over a movieclip nothing happens. Is there a way I can allow for the user to draw over movieclips? For example if I had a background of paper?
Here's the code I'm using for it:
// This code is for drawing the lines on the page //1. var drawingLine:MovieClip = new MovieClip(); addChildAt(drawingLine,0);
I need to draw on stage about 40,000 4x4 squares each a different color. The color is determined by an xml file. I have this working in as2 and have converted it to as3 the problem is the amount of time it takes to draw is causing cs4 to time out. I have extended the script time out to 60 seconds. In cs3 as2 it would draw the squares in about 15 seconds. I was hoping as3 cs4 would improve performance but seems to be the opposite. I have tried several methods such as adding children and various drawing variations. the bellow seems to work the best, but is still causing flash to crash.
I have created a flash program and I would like to run a second flash program from inside the first. To explain, say I am running a program that draws a circle and fills it with a color. Then, I have designed a second program that will divide a circle into sectors by entering percentages, to turn that circle into a pie chart. Is there a way to be running the "draw a circle" program and have a button that opens the "divide the circle into sectors" program in a new window and then passes information from that program to the first program. I am sure I will have to send the information from the second program to an XML file and then have the first program recieve it from the XML file (which I can do), but I don't know if I can run the second program from inside the first program.
I am trying to make a tutorial on how to use a web program. I have some screens from the website and I need to animate some text and arrows to show up on Q once the voice over mentions them. I have set marker tracks on my MP3 files, to which I want certain action to happen when the player reaches each track.
How or what do I need to know programming wise in order to interact with the web using c++. For instance i want to wrote a program that automatically sends invites to players on yahoo chess. How would i go about doing this?
I have just moved to cs3 (AS3). I am unable to make some programs run. For example I have downloaded the photo viewer from actionscript.org V2/Page1.html but when I run this program, it shows just blank screen nothing else. Even SWF file is showing the same. And it shows the error, "A definition for the document class could not be found in the classpath, so one will be automatically generated in the swf file upon export." While classpath is the same as of .FLA file.
i managed to zoom in 1 of my image instance when i click on it , and it can also be drag around.This image symbol will have a mask and action script is added in the symbol . However there are still other instances in my program which i do not know how to zoom . Is there any way to zoom in everything in my program?