Fixed graphics bug + updated docs
Fixed issue with getBounds being incorrect for graphics Updated docs Linted code
This commit is contained in:
parent
53506da65e
commit
7713731ab3
145 changed files with 15583 additions and 24078 deletions
|
@ -19,7 +19,7 @@
|
|||
|
||||
</div>
|
||||
<div class="yui3-u-1-4 version">
|
||||
<em>API Docs for: 1.3.0</em>
|
||||
<em>API Docs for: 1.4.0</em>
|
||||
</div>
|
||||
</div>
|
||||
<div id="bd" class="yui3-g">
|
||||
|
@ -45,6 +45,8 @@
|
|||
|
||||
<li><a href="../classes/AssetLoader.html">AssetLoader</a></li>
|
||||
|
||||
<li><a href="../classes/AtlasLoader.html">AtlasLoader</a></li>
|
||||
|
||||
<li><a href="../classes/BaseTexture.html">BaseTexture</a></li>
|
||||
|
||||
<li><a href="../classes/BitmapFontLoader.html">BitmapFontLoader</a></li>
|
||||
|
@ -61,7 +63,7 @@
|
|||
|
||||
<li><a href="../classes/ColorMatrixFilter.html">ColorMatrixFilter</a></li>
|
||||
|
||||
<li><a href="../classes/CustomRenderable.html">CustomRenderable</a></li>
|
||||
<li><a href="../classes/ColorStepFilter.html">ColorStepFilter</a></li>
|
||||
|
||||
<li><a href="../classes/DisplacementFilter.html">DisplacementFilter</a></li>
|
||||
|
||||
|
@ -75,7 +77,7 @@
|
|||
|
||||
<li><a href="../classes/Graphics.html">Graphics</a></li>
|
||||
|
||||
<li><a href="../classes/GreyFilter.html">GreyFilter</a></li>
|
||||
<li><a href="../classes/GrayFilter.html">GrayFilter</a></li>
|
||||
|
||||
<li><a href="../classes/ImageLoader.html">ImageLoader</a></li>
|
||||
|
||||
|
@ -87,6 +89,8 @@
|
|||
|
||||
<li><a href="../classes/PixelateFilter.html">PixelateFilter</a></li>
|
||||
|
||||
<li><a href="../classes/PIXI.PixiShader.html">PIXI.PixiShader</a></li>
|
||||
|
||||
<li><a href="../classes/Point.html">Point</a></li>
|
||||
|
||||
<li><a href="../classes/Polygon.html">Polygon</a></li>
|
||||
|
@ -109,10 +113,10 @@
|
|||
|
||||
<li><a href="../classes/Spine.html">Spine</a></li>
|
||||
|
||||
<li><a href="../classes/Sprite.html">Sprite</a></li>
|
||||
|
||||
<li><a href="../classes/SpriteSheetLoader.html">SpriteSheetLoader</a></li>
|
||||
|
||||
<li><a href="../classes/Sprite™.html">Sprite™</a></li>
|
||||
|
||||
<li><a href="../classes/Stage.html">Stage</a></li>
|
||||
|
||||
<li><a href="../classes/Text.html">Text</a></li>
|
||||
|
@ -121,8 +125,6 @@
|
|||
|
||||
<li><a href="../classes/TilingSprite.html">TilingSprite</a></li>
|
||||
|
||||
<li><a href="../classes/WebGLBatch.html">WebGLBatch</a></li>
|
||||
|
||||
<li><a href="../classes/WebGLRenderer.html">WebGLRenderer</a></li>
|
||||
|
||||
</ul>
|
||||
|
@ -176,66 +178,66 @@
|
|||
|
||||
PIXI.Strip = function(texture, width, height)
|
||||
{
|
||||
PIXI.DisplayObjectContainer.call( this );
|
||||
this.texture = texture;
|
||||
this.blendMode = PIXI.blendModes.NORMAL;
|
||||
PIXI.DisplayObjectContainer.call( this );
|
||||
this.texture = texture;
|
||||
this.blendMode = PIXI.blendModes.NORMAL;
|
||||
|
||||
try
|
||||
{
|
||||
this.uvs = new Float32Array([0, 1,
|
||||
1, 1,
|
||||
1, 0, 0,1]);
|
||||
try
|
||||
{
|
||||
this.uvs = new Float32Array([0, 1,
|
||||
1, 1,
|
||||
1, 0, 0,1]);
|
||||
|
||||
this.verticies = new Float32Array([0, 0,
|
||||
0,0,
|
||||
0,0, 0,
|
||||
0, 0]);
|
||||
this.verticies = new Float32Array([0, 0,
|
||||
0,0,
|
||||
0,0, 0,
|
||||
0, 0]);
|
||||
|
||||
this.colors = new Float32Array([1, 1, 1, 1]);
|
||||
this.colors = new Float32Array([1, 1, 1, 1]);
|
||||
|
||||
this.indices = new Uint16Array([0, 1, 2, 3]);
|
||||
}
|
||||
catch(error)
|
||||
{
|
||||
this.uvs = [0, 1,
|
||||
1, 1,
|
||||
1, 0, 0,1];
|
||||
this.indices = new Uint16Array([0, 1, 2, 3]);
|
||||
}
|
||||
catch(error)
|
||||
{
|
||||
this.uvs = [0, 1,
|
||||
1, 1,
|
||||
1, 0, 0,1];
|
||||
|
||||
this.verticies = [0, 0,
|
||||
0,0,
|
||||
0,0, 0,
|
||||
0, 0];
|
||||
this.verticies = [0, 0,
|
||||
0,0,
|
||||
0,0, 0,
|
||||
0, 0];
|
||||
|
||||
this.colors = [1, 1, 1, 1];
|
||||
this.colors = [1, 1, 1, 1];
|
||||
|
||||
this.indices = [0, 1, 2, 3];
|
||||
}
|
||||
this.indices = [0, 1, 2, 3];
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
this.uvs = new Float32Array()
|
||||
this.verticies = new Float32Array()
|
||||
this.colors = new Float32Array()
|
||||
this.indices = new Uint16Array()
|
||||
*/
|
||||
this.width = width;
|
||||
this.height = height;
|
||||
/*
|
||||
this.uvs = new Float32Array()
|
||||
this.verticies = new Float32Array()
|
||||
this.colors = new Float32Array()
|
||||
this.indices = new Uint16Array()
|
||||
*/
|
||||
this.width = width;
|
||||
this.height = height;
|
||||
|
||||
// load the texture!
|
||||
if(texture.baseTexture.hasLoaded)
|
||||
{
|
||||
this.width = this.texture.frame.width;
|
||||
this.height = this.texture.frame.height;
|
||||
this.updateFrame = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
this.onTextureUpdateBind = this.onTextureUpdate.bind(this);
|
||||
this.texture.addEventListener( 'update', this.onTextureUpdateBind );
|
||||
}
|
||||
// load the texture!
|
||||
if(texture.baseTexture.hasLoaded)
|
||||
{
|
||||
this.width = this.texture.frame.width;
|
||||
this.height = this.texture.frame.height;
|
||||
this.updateFrame = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
this.onTextureUpdateBind = this.onTextureUpdate.bind(this);
|
||||
this.texture.addEventListener( 'update', this.onTextureUpdateBind );
|
||||
}
|
||||
|
||||
this.renderable = true;
|
||||
}
|
||||
this.renderable = true;
|
||||
};
|
||||
|
||||
// constructor
|
||||
PIXI.Strip.prototype = Object.create( PIXI.DisplayObjectContainer.prototype );
|
||||
|
@ -243,23 +245,22 @@ PIXI.Strip.prototype.constructor = PIXI.Strip;
|
|||
|
||||
PIXI.Strip.prototype.setTexture = function(texture)
|
||||
{
|
||||
//TODO SET THE TEXTURES
|
||||
//TODO VISIBILITY
|
||||
//TODO SET THE TEXTURES
|
||||
//TODO VISIBILITY
|
||||
|
||||
// stop current texture
|
||||
this.texture = texture;
|
||||
this.width = texture.frame.width;
|
||||
this.height = texture.frame.height;
|
||||
this.updateFrame = true;
|
||||
}
|
||||
// stop current texture
|
||||
this.texture = texture;
|
||||
this.width = texture.frame.width;
|
||||
this.height = texture.frame.height;
|
||||
this.updateFrame = true;
|
||||
};
|
||||
|
||||
PIXI.Strip.prototype.onTextureUpdate = function(event)
|
||||
PIXI.Strip.prototype.onTextureUpdate = function()
|
||||
{
|
||||
this.updateFrame = true;
|
||||
}
|
||||
this.updateFrame = true;
|
||||
};
|
||||
// some helper functions..
|
||||
|
||||
|
||||
</pre>
|
||||
</div>
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue