/    Sign up×
Community /Pin to ProfileBookmark

[RESOLVED] ActionScript Error #2015

Hi gang,
at best I’m a novice AS programmer; I like to use filter transitions in my banners for webpages (clients like it). I’ve got by downloading a component and swapping in my images for the demo images and sometimes adding in a little AS for tweaking how it played.

Following this pattern, I’ve run into a problem, specifically Error 2015; I asked Flash-Filter.net about it but they have yet to respond to my email. This component is a water-drop transition effect from one banner to another. The demo program code is not complicated here it is:

/* *************************** */
// CHANGE PARAMS HERE
image_movieclip_array = [
// [linkageNameOfMovieClip, waitAfterImage]
[Image1, 1000],
[Image2, 1000],
[Image3, 1000]
]
/* ***
************************ */

// init vars
var waitInterval:Number;
var stage_img_array:Array = new Array();
var ticker:Number = 0;
var depthsTicker:Number;

// attach movieclip
for(var i = 0; i < image_movieclip_array.length; i++){
var img:MovieClip = new image_movieclip_array[i][0]();
addChild(img);
stage_img_array.push(img);
}

// set vars
var oldImage = stage_img_array[0];
var newImage;
var ff_component?ripTransitionEffectAS3;

// start transition
nextImage();

function nextImage(){

// clear interval
clearInterval(waitInterval);

// set vars
if(++ticker == image_movieclip_array.length) ticker = 0;

if(ff_component != null)
{
ff_component.removeFilter();
ff_component = null;
}

// set vars
newImage = stage_img_array[ticker];

removeChild(newImage);
addChild(newImage);

ff_component = new DripTransitionEffectAS3();
addChild(ff_component);

// init filter
ff_component.init(oldImage, 75, Math.round(Math.random()*9999), true, false);
ff_component.addEventListener(DripTransitionEffectAS3.ANIMATION_DONE, onComplete);

}

// on complete method
function onComplete(e:Event)
{
// set wait interval
waitInterval = setInterval(nextImage, image_movieclip_array[ticker][1]);
oldImage = newImage;
}

[B]Here’s the error message:[/B]
ArgumentError: Error #2015: Invalid BitmapData.
at flash.display::BitmapData()
at net.flashfilter.as3.effects::SuperEffect/getSourceBitmapData()
at net.flashfilter.as3.effects::SuperEffect/initSuper()
at net.flashfilter.as3.effects::E25_drip/init()
at test_a_fla::MainTimeline/nextImage()
at test_a_fla::MainTimeline/frame1()

I set my linkage class to the Image1, Image2, etc . in the section at the top regarding parameters. I keep getting the above error 2015. Do I need to import BitmapData resources?

Any suggestions?

captsig

to post a comment

1 Comments(s)

Copy linkTweet thisAlerts:
@captsigauthorMay 13.2012 — I found my mistake; when replacing the demo images with my own, in the library, I converted them to symbols and specified the linkage class in the properties panel. I went back and did everything again, but with one change, I actually dragged the images onto the stage, there I converted to symbol and set the linkage class. That simple step must set up the bitmap assets automatically in the background. Of course being a novice, I'm only guessing. Sometimes it helps to have dumb luck.

captsig
×

Success!

Help @captsig spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 4.30,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,

tipper: @Samric24,
tipped: article
amount: 1000 SATS,
)...