codice:
// --------------
// transition 10
// --------------
ImageLoader.prototype.transition10 = function(){
var w = this.clip._width
var h = this.clip._height
var num = 10
var diff = 5
var alpha_diff = 100/num
var clip = this.clip
for(var a = 0; a < num; a++){
if(a > 0){
var clip = this.createEmptyMovieClip('clip' + a, -(100 + a))
clip._alpha = 0
clip.loadMovie(this.clip._url)
}
clip._x = (-w) + (a*(diff++))
var mask = this.createEmptyMovieClip('mask'+a,(100+a))
mask._visible = 0
with(mask){
beginFill(0x00,100)
lineTo(w,0)
lineTo(w,h)
lineTo(0,h)
endFill()
}
}
this.onEnterFrame = function(){
_loaded = true
for(var a = 1; a < num; a++){
if (this['clip' + a]._url == this._url || this['clip' + a].getBytesLoaded () < this['clip' + a].getBytesTotal () || this['clip' + a].getBytesTotal () < 4) {
var _loaded = false
return;
}
}
if(_loaded){
for(var a = 0; a < num; a++){
this['clip' + a]._alpha = 100 - (a*alpha_diff)
this.clip._alpha = 100
if(a==0){
var clip = this.clip
} else {
var clip = this['clip'+a]
}
clip.count = 0
clip.steps = steps
clip.x_init = clip._x
clip.setMask( this['mask'+a] )
this['mask' + a]._visible = 1
clip.onEnterFrame = function(){
if(this._x + 10 >= 0){
this._x = 0
delete this.onEnterFrame;
return
}
this._x += 10
}
}
delete this.onEnterFrame
}
}
}
// --------------
// transition 11
// --------------
ImageLoader.prototype.transition11 = function(){
var w = this.clip._width
var h = this.clip._height
var num = 9
var diff = 10
var alpha_diff = 100/num
var clip = this.clip
var steps = 45
for(var a = 0; a < num; a++){
if(a > 0){
var clip = this.createEmptyMovieClip('clip' + a, -(100 + a))
clip._alpha = 0
clip.loadMovie(this.clip._url)
}
var mask = this.createEmptyMovieClip('mask'+a,(100+a))
mask._visible = 0
mask._x = -(w + (a*diff++))
mask._alpha = 40
mask.steps = steps + num
mask._k = 0
mask._move = w/steps
with(mask){
beginFill(0x00,100)
lineTo(w,0)
lineTo(w,h)
lineTo(0,h)
endFill()
}
}
this.onEnterFrame = function(){
_loaded = true
for(var a = 1; a < num; a++){
if (this['clip' + a]._url == this._url || this['clip' + a].getBytesLoaded () < this['clip' + a].getBytesTotal () || this['clip' + a].getBytesTotal () < 4) {
var _loaded = false
return;
}
}
if(_loaded){
for(var a = 0; a < num; a++){
if(a==0){
var clip = this.clip
} else {
var clip = this['clip'+a]
}
clip._alpha = (100/(num+1))*(a+1)
clip.setMask( this['mask'+a] )
this['mask' + a]._visible = 1
this['mask' + a].onEnterFrame = function(){
if(this._x >= 0){
this._x = 0
this.unloadMovie()
delete this.onEnterFrame;
return;
}
this._x += this._move
this._k++
}
}
this['clip'+(a-1)]._alpha = 100
delete this.onEnterFrame
}
}
}
Object.registerClass ("ImageLoader", ImageLoader);
#endinitclip
Questo è il file XML :
codice:
<?xml version="1.0"?>
<!--
set transition number from 1 to 9
set transition number to 0 for random effect
-->
<RSS PAUSE="4000">
<IMAGE TRANSITION="11">IM000241.jpg</IMAGE>
<IMAGE TRANSITION="11">IM000282.jpg</IMAGE>
</RSS>
Ecco sapete mica come posso fare ?
(esiste un altro file del genere che ha anche questa opzione ?)
Ultima domanda è possibile tramite ASP leggere il contenuto di una cartella (che contiene le JPG) e stampare un file XML tipo quello sopra ? (le foto sono + di 200 e difficilmente gestibili manualmente)
Vi prego aiutatemi (mi serve per un cd di un matrimonio
)
Andrea