• Content Count

  • Joined

  • Last visited

About jonforum

  • Rank
    Advanced Member
  • Birthday 02/01/1987

Profile Information

  • Gender
  • Location

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. jonforum

    Resizing Game Problem

    yep me to, try with @ivan.popelyshev it a magic russian dev from pixiJs . But on my side i was try but i can not help you more sorry my friend.
  2. jonforum

    Resizing Game Problem

    hum , i don't know, the code i share you work for my side. Example here at right, i have my app set to 1920x1080 resized to to fake mobile frame ~~767x431 and it work . i have no idea where is your issue, it strange, maybe we don't have similar context. humm...
  3. jonforum

    Resizing Game Problem

    Are you able to send a printScreen or preview of result what you target? Your sprite does not mean much, not knowing what it should represent. If you can send a target result vs current result , this can help to understand what your target behavior.
  4. jonforum

    Resizing Game Problem

    to get ratio of scale based on your resolution you can create a custom global method // Get a ratio for resize in a bounds function getRatio(obj, w, h) { let r = Math.min(w / obj.width, h / obj.height); return r; }; this will based on you max resolution game. In 2d sprite game, alway make ressource more resolution from what you really need for take zoom. Also Example triks on my side is 1920x1080 max resolution screen, but i build all my ressource for a 8k game, so when i zoom, i don't have pixel issue or need compute on another textures. so app.stage.scale.set ( getRatio(app.stage,maxWidth,maxHeight) ); should help you
  5. jonforum

    Resizing Game Problem

    i dont know if this can help you because am not fully understand, maybe more information can help. But here how i add zoom engine with pixijs and how the game are responsive to the node js app resolution and redimention
  6. jonforum

    Tools to make custom layouts / positioning of images

    you have some photoshop script to do that's. On my side i use one from esotericsoftware to do this. It free but i suggest to read license to be sure 100% sure.
  7. jonforum

    Spine (Keyframed) V Animated Sprite Performance

    i will probably try a day, with small intro video ~~ 12 second. With AE you can render the video frames to sequence png 32 this will give me ~~360 frames from video, + packing in texturePacker multipack and see if the performance and memory are better than the crap HTML video canvas player 😂. We lost the Audio api, but maybe PixiJS Sound can give some good result to synchronize with pixijs animated sprite.
  8. jonforum

    Spine (Keyframed) V Animated Sprite Performance

    it is not really comparable, the 2 are of interest rather different! *If you want made sequential PNG, you should use pixijs animated sprites *If you want made complexe rigging animation but light weight, you should use spine. it's not a technical benchmark but in my last performance test, my engine can hold ~~200 spine animated object before spike lag. and ~~800 animated sprites before spikes fps. My personal conclusion is Animated sprites are very more lightweight than spine, so recommande you to use pixi animated sprite to make simple sequential textures key animations. i get this result on a i7 920 and gtx 1070
  9. jonforum

    Video sprite not showing up

    hi , i remember get some issue with video loader and first frame freezing. By default the autoPlay is alway force to true. here a good way to create a video controler const texture = PIXI.Texture.fromVideo('data2/Video/intro/vidA1.webm'); const videoSprite = new PIXI.Sprite(texture); const videoControler = texture.baseTexture.source; videoSprite.width = 1920; videoSprite.height = 1080; videoControler.currentTime = 12.2; videoControler.onended = function(){ this.nextVideo(); }.bind(this); this.addChild(videoSprite); this.videoControler = videoControler; and to start video Scene_IntroVideo.prototype.start = function() {;; }; if you have issue, try hack PIXI to force autoplay to the default source autoPlay It work for me
  10. jonforum

    Unable to pause video immediately on load?

    also related here, pixi don't take the source, so just add source to autoplay. It one line edit! the problem is that pixi forces the autoplay, without take the source parameter. this dont allow to force video to stop.
  11. jonforum

    Best performance way to extends a PIXI class ?

    the reason why i use self invoked it because when my app boot, i want assign to PIXI CLASS a new type of container. But i don't want hack the vanilla pixi , it's getting too difficult to handle in my head. So for keep clean my workflow, i create a new js file and i hack pixi vanilla in this file, on the app boot. The issue with your suggestion (don't use self invoked) is that PIXI will does not inherit the new class. The class will be global , and i don't want overload global scope. in my projet contex , i wan special container for all my objs const cage = new PIXI.CageContainer(dataBase); and all other basic elements without game objs will be basic pixi container. const cage = new PIXI.Container(); i don't know if you understand 🤔 !
  12. Hello everyone What is the most powerful and performance way to extends a PIXI class? Example from my side, I need the native PIXI.Container class but with more methods and properties, and here's how i proceed. PIXI.ContainerData = (function () { class ContainerData extends PIXI.Container { constructor() { super(); this.Sprites = {}; // others custom proprety for game obj }; get d() { return this.Sprites.d }; // return diffuse sprites get n() { return this.Sprites.n }; // return normals sprites //TODO: spine normal are arrays }; ContainerData.prototype.createJson = function(dataValues) { }; ContainerData.prototype.asignJson = function(dataValues) { }; //END return ContainerData; })(); I also know another way to extends functional prototyping. example: function ContainerData() {; this.initialize(); }; ContainerData.prototype = Object.create(PIXI.Container.prototype); ContainerData.prototype.constructor = ContainerData; ContainerData.prototype.initialize = function () { this.Sprites = {}; }; I wondering about the cleanest and most efficient techniques to properly extend a class pixi? But especially on the most optimal way, knowing that JS need scan all the prototypes from the bottom to the top! The first technique worries me a little because in my console, Is look like that all the prototypes are cloned by reference and duplicate! So, i am interested in different techniques and advice. I am therefore looking for the most equitable approach between performance (speed) but also the readability for debugging. Thanks in advance.
  13. jonforum

    Load all assets in a folder

    you need use a low-level environment for running server-side JavaScript. take a look on the module node.js. "nwjs" It allow you to scan your systems files and make a files list for the loader. and the official doc, but not completed.
  14. jonforum

    What does it take to learn Pixi?

    will your book be translated into several languages by an editor?
  15. jonforum

    What does it take to learn Pixi?

    On my side, i learned html, css, js, nwjs and after pixijs i use rmmv, it a jpn software and basic framework using pixijs and nwjs in background, and very easy to debug experiment and learn. Open source so a lot of plugin made by comunauty are available with pixijs modules.