visgotti

Members
  • Content Count

    10
  • Joined

  • Last visited

About visgotti

  • Rank
    Member

Recent Profile Visitors

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

  1. visgotti

    ColorReplaceFilter vs Tinting

    Thanks for the quick responses Sent pm with info for that slack invite
  2. visgotti

    ColorReplaceFilter vs Tinting

    Awesome, thank you. I don't have experience with shaders but I was going to look into using color replacement anyway for changing color palettes for some of my character clothing, thanks for the info.
  3. visgotti

    ColorReplaceFilter vs Tinting

    Hi, right now I'm using tinting to change the color of my bitmap text, but I want to be able to change the stroke too.. as of now the stroke is black and the inside is white, so changing the tint works perfectly but what if I want to change the stroke? Is it worth having a separate sprite from the same texture overlap eachother, one with a white stroke and transparent fill color and one with no stroke and white fill color, then tinting each one appropriately.. The alternative is to use color replace filter and chang the black and white that way, but I know filters can be extremely expensive while tinting is free. But I'm wondering if color replace under the hood works similarly to tinting and I can get away with it? Thanks
  4. visgotti

    Render in node extremey slow

    fs.readFile('bunny.png', function(err, bunny) { img = new Image; img.src = bunny; var timeNow = Date.now(); for(var i = 0; i < 500; i++) { ctx.drawImage(img, 50, 50, 50, 50); } var timeAfter = Date.now(); console.log('time:', timeAfter-timeNow) }) time: 807 Yep you're right. 800 ms for this.. Looks like I'll have to write something that spawns enough processes so I can render scenes for my targeted framerate.. No idea what other direction I can go in.
  5. visgotti

    Render in node extremey slow

    I wouldn't say it's really too heavy each bunny adds ~10 ms to the render. for (var i = 0; i < 25; i++) { var bunny = new PIXI.Sprite(texture); bunny.anchor.set(0.5); bunny.x = (i % 5) * 40; bunny.y = Math.floor(i / 5) * 40; mainStage.addChild(bunny); }
  6. visgotti

    Render in node extremey slow

    Can't tell if this is sarcasm or actual advice..
  7. visgotti

    Render in node extremey slow

    Hey obviously I know PIXI.js is meant for html5.. but I'm trying to have a server that records my game and converts it to a video. So to do this I need to render images of the current canvas at at least 20 fps In the web browser this would be obviously simple. The following code- var timeNow = Date.now(); renderer.render(mainStage); var timeAfter = Date.now(); console.log(timeAfter - timeNow) In web browsers returns 1 ms In node it returns anywhere from 180-300 I'm shimming PIXIjs with jsdom and node-canvas.. I don't understand the underlying technologies enough to understand why there's such a big difference.
  8. I’m working on an RPG type game and plan on having eventually thousands of skins for bodies, heads, weapons, etc. If there’s 20 people on the screen at the same time it can be up to 100 different textures being rendered at once. That’s just from the player model. would dynamically combining textures based on who is in your screen be a good solution to this problem? That seems too intensive to do on the fly though especially if new people are constantly moving in and out of your view.
  9. visgotti

    Increase optimization of my Tiled Map rendering

    That library does not support TiledMaps. I don't actually think that's the problem actually. I think my computer is just lacking a GPU so my FPS sucks. I'm still getting pretty shitty FPS with canvas as well though so I'm not sure.
  10. Here's my current logic split up the tileset image into an array of 64 x 64 textures (the index correlates to the tile id) split up the map into sections max size of each section is 640 x 640 and create a container for that section. create a sprite for each tile in that section, and add it to the section's container check if the section container is visible to the player based on the current screen size, if it is then set that section's container visible to true, otherwise set it to false. I'm getting terrible performance doing it this way, if I make the screen small my fps is fine, but once I maximize the screen or make it a little larger the fps drops significantly. Does anyone see the flaw in my system as to why I'd be getting terrible performance doing it this way?