ActionScript 3.0 :: Making Polygons Over Colored Image Parts
Jul 8, 2010
I have .ppm files which are the result of using a segmentation algorithm on images of things.These basically look like a jigsaw puzzle of randomly colored funny-shaped segments. I'd like for each segment to be selectable.I want them to change color on mouseover, so I can't just use bitmapData. getColorBounds (that's the best thing I could find searching for possible solutions).As far as I know, the best way to make a specific shape selectable is to draw a polygon using graphics.lineTo, etc. Assuming that that is true, is there any way to draw a polygon that roughly follows a jaggedly-shaped area of a certain color? Or is this just not something flash can handle?
View 1 Replies
Similar Posts:
Oct 12, 2009
How can i change colored image to black and white using actionscript?
i found a tutorial a while back but i cant find it now
i load the image and then draw it as bitmap.
View 2 Replies
Sep 8, 2010
I am importing a series of mockups of a website into Flash CS5 as symbols, and it already has elements drawn in Illustrator CS5 that I want to use as buttons. I want to place those symbols into the Timeline and just use simple AS3 to make it go from one mockup screen to the other to make it into a slightly more functional mockup. 1. How can I take the mockups done entirely in Illustrator and make the buttons functional?
View 2 Replies
Oct 8, 2010
I'm trying to split an image (in a MC on the stage) into a variable number of parts.
It's not working properly, and I'm pretty sure it's because I'm re-using the bitmapdata and bitmap I create before the loop...
The MC I'm splitting is called 'back'.
ActionScript Code:
import flash.display.Bitmap;
import flash.display.BitmapData;
import flash.geom.Rectangle;
[Code]....
View 2 Replies
May 27, 2009
I was visiting this site mentioned in a book about flash we sites [URL]. and i really got curious about the effect of the picture in the background. when you roll over the area they practically have an alpha tween...but i think it's not just alpha tween...i noticed that the brightest parts of the image you have rolling over are also the darkest when the Tween begin. is kind of "selective alphaTween"?.
View 2 Replies
Aug 23, 2010
Lines and polygons generated from a database..possible ? we have done so, that one can have e.g. spots populate a map in Flash with their positions coming from an xml feed database. The map having been drawn in Adobe/macromedia Freehand then imported into Flash.If we wish to show areas, e.g. development sites, can those areas likewise be shown from a database, perhaps the points that form the edge of the area being indicated by eastings and northings co-ordinates held in the database ? If someone alters a co-ordinate, the area then changes shape without being 'drawn' or edited using the usual tools.What of fills and alpha values, can they be controlled from a database ? If we wish to show traffic flow by having a line get fatter, can line width be altered via a database ?
View 2 Replies
Apr 14, 2011
I'm making a Flash game, and I've encountered a really weird problem while trying to draw a polygonal shape in Box2D.
Here's the code I use:
var fixtureDefs:Array = new Array();
...
var fDef:b2FixtureDef = new b2FixtureDef();
fDef.density = 0;
[code]....
Where vertexArray is a valid array containing 4 b2Vec2 vertices, making up a convex shape.The problem is, when I test, collisions don't work right for that body. Most other objects -enemies, user-controlled characters - pass straight through, as if the body isn't there at all. Some raycasts pass through as well.
Infuriatingly enough, one kind of bodies I have (a custom enemy) somehow does detect the body and collides with it. The raycasts that particular kind of enemy attempts do work - when your character hides behind the polygon, it's like they can't see him.The other weird thing: when I try the same code, only go for SetAsBox instead of SetAsArray, it works exactly as it should.I'm using a custom ContactListener class, but I haven't done any contact filtering (unless it's possible to do that without realising).I'm using the Flash 9 version of Box2D 2.1a.
View 2 Replies
May 15, 2010
I am looking for a easy way to convert Autocad polygons to swf files. Is there a converter for that? Or is there an intermediatory format that can be used to convert from polygons to the adobe flash swfs. Each polygon would be a swf file.
View 2 Replies
Mar 14, 2008
Basically I have a prototype that creates polygons based on an array. works well. I then have another prototype that's supposed to create polygons using said polygon prototype.
So the below is:
1 - the polyMaker prototype
2 - an array of arrays ($arrowListB). basically each array item should be a new polygon.
3 - the problematic genArrows prototype.
What it should do is loop through the $arrowListB array and create a container clip ($cont). Within each container clip it should make a $arrowClip to be used in making the polygon (an arrow actually). It works until I get to the line after creating the movieclips:
Code:
$arrowClip.polyMaker(..arguments..)
Once I put that line in, it only makes one polygon and doesn't create the other (7 in this case) movie clips. I'm not sure if I'm just not referencing correctly or what.
[Code].....
View 1 Replies
Apr 21, 2010
I would like to display a SVG layer (polygons) over the openlayers tiles in a HTML page, or alternatively, load my SVG in flash and have the OL tiles rendered into flash as well.
View 2 Replies
Mar 7, 2011
was wondering if anyone could assist me with some actionscript. I am working on a project similar to this (thehideout.org.uk/refuge/) and making the background image move around as if it the scene is a POV.
View 1 Replies
Feb 21, 2012
I need the ActionScript (2.0): 1) When rolling over a moving image (like a filmstrip), I want the image to stop and then it zooms into a larger image. 2) Then when you click on the larger image, it goes to another URL page in my webiste.
View 9 Replies
Aug 16, 2004
I have this actionscript:
Code:
// **** Load XML ****************************
myXML = new XML();
myXML.ignoreWhite = true;
receiverXML = new XML();
[Code].....
But how can I get these two lines to appear in red and have an url ? :
Code:
dinkost.htmlText = "DinKost" + "
";
dinkost.htmlText += "- http://www.dinkost.no";
View 1 Replies
Jun 26, 2009
I'm having a problem in one of my fla files. I'm not sure if I changed the view or what I did exactly, but now all I have is colored outlines around where images are supposed to be. All of the text has turned different colors as well.
Attachments: flash-problem.jpg (308.2 K)
View 5 Replies
Oct 28, 2009
I have a bitmap I broke into vectors and I need to select each vector that is the color red (#ff0000) with actionscript.
View 7 Replies
Sep 10, 2009
I'm attempting a neat little effect where I've got a fellow walking (already drawn and animated) and I'm using him as a mask over the top of a simple colored rectangle - the idea being, by changing the color of the rectangle, I can have a walking man with color effects happening. At this stage the square is just green, because the mask is not quite working correctly. The edges of the animated mask glitch up and don't work as expected
View 5 Replies
Mar 15, 2012
I need to generate colored QR codes in AS3. Is their any library available for that? Can zxing do this?
View 1 Replies
Jun 23, 2006
I loop the text from database and after I need in Flash to have certain Array index have in different color in my HTML text.[code]
View 1 Replies
Jun 20, 2010
Is there a color transform tool that lets me affect the brightness of colored pixels only? For example, if I have an image that has a lot of grays and blacks, but a colored dot in the center, is it possible to only affect the brightness of the colored portion?
The solution I'm looking for does not involve making the colored dot in the center its own movie clip, just so you know.
View 2 Replies
Jan 20, 2011
I am trying to draw random colored rectangles. I want to have them everywhere. Repeat them at X and Y. Its just repeating at X. Dunno why it dont want to take "for loop" at Y position
[Code]....
View 6 Replies
Jun 10, 2009
Is there a way to have Dynamic Text non-selectable and not have a white background? Such as a transparent background?
I'm looking to dynamically change text over a colored background.
View 2 Replies
May 19, 2009
I am trying to create a movieclip in which different colored birds are flying..I am tring to duplicate two or more MovieClips at the same time..but only either of them Works How should I modify the code so that I can achieve that ?
PHP Code:
function birds() {
for (m=1; m<=10; m++) {
firstEnem y= "bird"+1;
[code].....
View 2 Replies
Apr 12, 2011
I'm trying to emulate the transition effect from the site venuliving.com (I'd post the link but I don't have enough posts).
When you click through the various sections, coloured bars expand and move across the site, they hold while subtly moving and then shrink out once the section has loaded.
how this sort of thing is achieved? I've been considering creating the whole thing using coloured rectangles and TweenMax but I'm wondering if this was created dynamically in AS3? Or if it's a customization of some existing transition?
View 3 Replies
Dec 20, 2009
I'm playing around since days with the Color.Matrix.Filter and cant get it working. The Problem is that i have to implement it to a existing project which was done by someone else.If i do it from scratch it works.COLOR TWEEN FROM GRAY TO COLORED ( Normal ) ON MOUSE ROLL OVER Existing Code ( not on Frame one of the Project, its inside a Movieclip which will be placed on frame one of the main stage / scene.
//Original Values
originX = this._x;
originScale = 48
[code].....
View 0 Replies
Apr 17, 2012
I've got an array of Strings each of which have been input by a series of coloured buttons with sounds attached. When a play button is pressed the strings that correspond to different coloured sounds should play one after the other. Instead they all play at the same time as one jumbled mess of noise and I have tried everything to get it to work. The trace shows that the for loop through the array seems to be doing the right thing which is why I can't understand why it won't just play back one after the other.
This is the code for the play button:
PlayBTN.onRelease = function(){
trace("PlayButton Pressed");
for(var i:Number =0; i<songArray.length; ++i){
trace("Inside Loop");
trace(i);
[Code] .....
View 1 Replies
Dec 7, 2004
I have been playing about with the "Changing colors with Actionscript" FLA found on this site. Basically, when you move your mouse over a coloured box the movie clip changes to the corresponding color. This is the AS
[Code]...
View 1 Replies
Mar 13, 2008
does anyone know how to make an image flip over like the facebook and myspace links on this page?
View 6 Replies
Jun 26, 2009
I need help making a few of my buttons open images, I need the images to basically pop-up full size, and with a click on the image, it goes away. I require some sort of framework script for this
View 1 Replies
Aug 23, 2010
i m trying to make Image gallery and i hv made 2 classe, and I hv movieclip on my library exported by name thumbmc. and the problem is movieclip of library is not coming on stage
and the classes are
gallery.as(Document class)
thumbs.as
[code]....
View 2 Replies
Mar 27, 2009
[URL] On this site it has this Image Carousel controlled by moving my mouse side to side, is there a flash component, or some flash script i could use/buy?
View 1 Replies