Jump to content

lancety

Members
  • Content Count

    4
  • Joined

  • Last visited

About lancety

  • Rank
    Newbie

Recent Profile Visitors

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

  1. I noticed the BlurFilter takes 0.7ms per frame, which is not good. So I made little further improvement. Firstly, make a container to draw all the regions on graphics same as above, then instead of generateTexture directly from container, I applied BlurFilter to the continer first, so when generateTexture, it uses BlurFilter effect on graphics output, then the generateTexture Linear scale will be smoothed beause of the blur effect, which with make a even better result than above step1 result. ALSO more improtantly, it does not require render BlurFilter every frame;
  2. I just worked out a way to make the blur looks good enough as I need. how do you think @ivan.popelyshev what I did: 1. background regions map blur - I simply made a BaseRenderTexture on the background graphic and made a sprite from it, the texture is generated with Linear ScaleMode, and make it low resolution to make basic color gradient drawRegionShape(containerTemp, cachedMap, new MapColorDiscrete(), true, true); const bgSprite = new PixiSprite(pixiTool.generateTexture(containerTemp, 1, 2)); 2. apply a BlurFilter to the same sprite - this made a smooth gradient over the Sc
  3. thanks @ivan.popelyshev, I spend this morning looking for how to implement gradient shader on polygon edge, did not work out yet, will keep trying. Using rope for each region will make the logic more complex and I prefer the gradient option, by looking for the solution, I can improve my shader skill as well. I need to mention one thing as well about the map, other than polygon data for each region, I also have a mesh for all regions, I guess it will be easier to make the gradiant between regions on this map data, right?
  4. In my top-down view game, the terrain is formated with many polygon regions. each region has a different biome type. such as the below screenshot, one is a forest, another one has snow. It does not look good with a clear edge between the 2 regions. I want to make the edge colour blended, so the colour is smoothly transferred. appreciate any help, cheers.
×
×
  • Create New...