charlie_says

Members
  • Content count

    208
  • Joined

  • Last visited

  • Days Won

    1

charlie_says last won the day on August 25 2014

charlie_says had the most liked content!

About charlie_says

  • Rank
    Advanced Member
  • Birthday 12/12/1972

Contact Methods

  • Website URL
    http://playsnicely.co.uk
  • Twitter
    playsnicely

Profile Information

  • Gender
    Male
  • Location
    Southampton

Recent Profile Visitors

1,405 profile views
  1. charlie_says

    Can a html <img> use a Pixi Texture object?

    I've been a slightly different variant: using a PIXI.Sprite (which has additional content) as an image source var imgSRC = renderer.extract.canvas(mySprite).toDataURL('image/png'); var img = document.createElement('IMG'); img.src = imgSRC; img.style.width = '100%'; img.style.height = 'auto'; document.body.appendChild(img);
  2. charlie_says

    Should I use Phaser Graphics for UI or go with HTML5?

    I think the other answers here are good, and apologies if I misread your question. The only thing I wonder about using HTML elements over the canvas is if you have some kind of dynamic resizing, it could then be trickier to move the the HTML elements (although, it would still be possible.) The one area where it would definitely be easier would be that of some sort of text input field (although, I'm a little out of date with phaser plug-ins and maybe there's a good one now.)
  3. charlie_says

    Should I use Phaser Graphics for UI or go with HTML5?

    I recently was engaged to do a project for a new client, they, as part of the interview process asked me to to a test. The test was making an animated chart on canvas *without* a framework. Fair test I thought, and I did it. But, I was so relieved I did the test from home rather than in their office, as, I swore NON-STOP for the 3 hours it took me. There's no point reinventing the wheel - use a framework.
  4. charlie_says

    PIXI-SOUND is not working in IE11 11.0.56

    This is the version of IE11 I'm using. (I say using, but what I mean is: have available on my PC.) (edit - apologies, not sure why this image is massive, but...)
  5. charlie_says

    PIXI-SOUND is not working in IE11 11.0.56

    My version of IE is 11.0.60 and PIXI sound seems to work fine in it. @jonforum whilst I don't disagree with what you're saying, I'm just winding up a project which had to support IE11, not my choice, the client stipulated it. (And yes, it was a massive pain.)
  6. charlie_says

    PIXI sound & playback started

    thanks @botmaster that's all very useful. I did a ticker to check when the mediaelement progress > 0 - and that did work, although as some of the clips are long, the wait was 'uncomfortable' Unfortunately my use case has a lot of audio clips which need to be sequenced (and played alongside a separate video clip). This means I delete them from the cache after use (and they are expected to only be viewed once anyway.) It was working ok, but any network slow down caused it to fail. Ultimately, I've made separate arrangements for IE11.
  7. charlie_says

    PIXI sound & playback started

    I'm using PIXI.sound in my project, and it's working very well. But, I'm finding that IE11 (yeah, I know) is very slow to play MP3s. What I'd like to do is have an onstarted event when the playback has actually begun but there doesn't seem to be anything in PIXI.sound that I can use this way. Can anyone tell me a way to add an event listener so I can confirm the playback of an audio clip has started.
  8. charlie_says

    PIXI loader error (loader is running)

    ahh... ok I found an issue today that loading video like this: let options: PIXI.loaders.LoaderOptions = { loadType: PIXI.loaders.Resource.LOAD_TYPE.VIDEO, metaData: { mimeType: 'video/' + videoType } }; this._videoLoader.add({ name: this._name, url: videoPathAndName + '.' + videoType, options }); this._videoLoader.on('error', this._errorVideo, this); this._videoLoader.on('progress', this._progressVideo, this); this._videoLoader.on('complete', this._confirmedLoadFirstVideo, this); fails on older devices (ipad1, kindle fire) so I've changed things so the video is loaded like this: let options: PIXI.loaders.LoaderOptions = { loadType: PIXI.loaders.Resource.LOAD_TYPE.VIDEO, metaData: { mimeType: 'video/' + videoType } }; this._videoTexture = PIXI.VideoBaseTexture.fromUrl({ name: this._name, src: videoPathAndName + '.' + videoType, options }); this._videoTexture.autoPlay = true; this._videoTexture.on('loaded', this._confirmedLoadFirstVideo, this); This appears to work, but is there anything (else) I should be aware of? (I've got a bit of further testing to check that I'm removing the videos from the cache correctly, although, initially it appears fine.)
  9. charlie_says

    PIXI loader error (loader is running)

    Sorry, I meant if you used the helper functions, I wasn't sure how (or if) the loader was exposed. Elsewhere I do use a loader directly for a video clip, I've now set this so it resets afterwards. Interestingly, I did quite a lot of experimenting with adding my own video tag to the page, but again hit different issues in different browsers. I think that I found the best way of loading video (generally) was to load it as xhr and make a video element from a blob, but, working this way meant that autoplay was lost on some browsers... Ultimately, after all these experiments, I went back to the simplest implementation (basically basetexture.fromURL) as the more complex ways whilst giving a little more control didn't improve the end result... (drifted off from the original topic here.)
  10. charlie_says

    PIXI loader error (loader is running)

    Thanks for this @xerver - I think some (if not all) of the issues I've been having with my current project may have been due to misunderstanding how the loader works/should be used. If I could trouble you for one more question: As videos get loaded 'a different way' (via fromFile/fromURL(s)) how would be the best way of chaining/sequencing their loading? As they don't have a loader, there's nothing to call reset to? Thanks!
  11. charlie_says

    PIXI loader error (loader is running)

    gotcha, thanks @xerver - although, I was expecting the previous load to be complete, as the new loading is only initiated on the complete event being fired from the previous. Is this to do with video loading being (at least in part) managed by the browser?
  12. charlie_says

    PIXI loader error (loader is running)

    Thanks @ivan.popelyshev adding the resource seems to resolve this issue.
  13. charlie_says

    PIXI loader error (loader is running)

    Sorry @ivan.popelyshev I didn't mean chain like that. What I'm doing is, loading a video, then loading an associated mp3. I wait until the video complete event fires before starting the audio - they use their own instantiation of a loader. But, sometimes it seems that the audio trips up - I expect this is because the video hasn't actually loaded, but, with all my tests/experiments there doesn't seem to be a way to conclusively find out if the video has loaded or not (browser buffering/caching etc.)
  14. charlie_says

    PIXI loader error (loader is running)

    Hi, I'm getting an error when trying to load some mp3s. The loading happens in a chain so the error: pixi.min.js:9 Uncaught Error: Cannot add resources while the loader is running. surprises me, as the previous load should be complete. So - is it possible to check if the loader is still loading? Also, does calling loader.reset() not stop any current loads? Thanks!
  15. charlie_says

    PIXI Loader handling failed loads

    thanks for all the replies!