• Content Count

  • Joined

  • Last visited

About fsrojas

  • Rank

Contact Methods

  • Twitter
  1. var button = PIXI.Sprite.fromFrame("button.png"); button.anchor.x = 0.5; button.anchor.y = 0.5; button.position.x = defaultWidth*0.5; button.position.y = defaultHeight*0.5; button.interactive = button.buttonMode = true; button.on("mousedown",button.mousedown); button.mousedown = function(eventData) { //Button event alert('mousedown!'); } stage.addChild( button ); var textureWhite = PIXI.Texture.fromImage("white.png"); var tilingWhite = new PIXI.extras.TilingSprite(textureWhite, defaultWidth, defaultHeight); tilingWhite.alpha = 0.2; tilingWhite.position.x = 0; tilingWhite.position.y = 0; stage.addChild (tilingWhite); //tilingWhite.visible = false;
  2. Try to add the pixi-spine library, you can find more info here -> https://github.com/pixijs/pixi-spine
  3. Hello, Let's say that i have an "Interactive" Sprite Button (sprite.interactive = true) ready for receiving click/touch events, and above of it there is a big TilingSprite (with the size of all screen) to create a Flash effect. The tiling sprite is visible (tilingSprite.visible = true) and its alpha oscillate between 0.1 to 0.5. The problem is when i want to touch/click the Sprite button nothing happens... The only way to receive a touch/click event is by setting tilingSprite.visible = false. Is there any way to set the interaction manager to "bypass" some elements like some TilingSprites or others?
  4. Apparently when i use a mask property in the rootContainer all the child sprites or containers with filters disappear, when i return the mask to null everything is in order again... any idea?
  5. Hi I'm using the last stable version of Pixi (v 1.6.1), for some reason when i do: mySprite.filters = [new PIXI.GrayFilter()];The sprite 'myFilter' turns invisible. Why is that? Also, i try to apply the same filter to a Container, and all the child objects turn invisible too...
  6. I've recently use this solution http://www.corsproxy.com/ for retrieve the texture and works fine, maybe we have a server-side problem now (PIXI is OK!). Thanks for your answer!
  7. I tried the latest dev build and the error has changed to: Cross-origin image load denied by Cross-Origin Resource Sharing policy. Tested on Safari, Firefox and Chrome.
  8. Any thoughts? The only way to set the crossorigin in PIXI is to set the crossorigin property (true), but this is not working. Can be a server problem maybe?
  9. Hi Guys, I recently using the last version of PIXI.js (1.5.1) and we are dealing with some problems with particular texture (that texture is in another host). Uncaught SecurityError: Failed to execute 'texImage2D' on 'WebGLRenderingContext': The cross-origin image at XXXXXX may not be loaded. To load the texture i'm using the asset loader and setting the crossorigin property by true. // assetsToInitloader has the url to the texture var preloader = new PIXI.AssetLoader(assetsToInitloader); preloader.onComplete = onAssetsInitloaded; preloader.crossorigin = true; preloader.load(); The same code is working fine on Safari, and having problems on Firefox and Chrome. Thanks in advance, Cheers!