Ashley's Forum Posts

  • Consider yourself a lucky recipient of the "Deadeye MSPaint thick red lines treatment"

  • For your information, the Construct codebase has been moved from CVS source control to SVN source control. SVN is much better, especially with the TortoiseSVN client!

    The CVS is still there, but will not be updated and I plan on closing it soon, it's only in case something vital was missed in the move and is only on CVS.

    The new SVN root is:

    https://construct.svn.sourceforge.net/svnroot/construct

    I've also added Canvas under SVN source control.

  • That's a good habit to get in to. However, interpreting the results depends on your hardware. If you've got a really crap graphics card for example, 250fps means pretty much all machines will be able to run your game with a nice overhead above V-sync rate. If you've got nVidia's latest $500 graphics card with 500 shader cores, that's equivalent to ordinary video cards choking to death, but your card is so obscenely powerful it can still pump out 250fps. (these cards can often get 10,000fps+ with simple games on unlimited framerate, which is pretty amazing)

    As for families, are there any bugs on the tracker about it? Have you been able to reproduce issues in a new .cap?

  • Are these bugs in the tracker? Which action was crashing with no meteorites? (It ought to handle zero objects fine)

  • Would an option to disable scaling pitch with timescale help?

  • Effects in Construct are processed over the entire bounding box of an image which, of course, gets bigger when the object rotates. That's something HLSL developers have to take in to consideration.

    I don't know if Madster's effect is finished, or if it's for his own purposes and that artefact does not bother him in the way he uses it. No offence, but this shouldn't concern you, you're being a little overzealous here.

  • You do not have permission to view this post

  • http://sourceforge.net/apps/mediawiki/c ... el_Shaders

    [quote:w90dumg1]float hotspotX; The X co-ordinate of the hotspot of the object with the effect, in texture co-ordinates.

    float hotspotY; The Y co-ordinate of the hotspot of the object with the effect, in texture co-ordinates.

    Angle isn't available I'm afraid...

  • You do not have permission to view this post

  • Lots of modern browsers have ******** javascript optimisations (involving compiling it to machine code) which is a plus.

  • You do not have permission to view this post

  • if I use external textures as in load files to fill sprites are the external textures all converted to PNG before the app runs?

    If you mean actions like "Load frame from file" at runtime, then no, they're decompressed and loaded directly in to video memory. There would be no point converting the file to PNG then loading in to video memory! That would be the same as decompress source file -> recompress source file as PNG -> decompress PNG -> load to video memory!

    [quote:20r9lmez]Is it faster to use external textures instead of ones inside the cap?

    Probably not, it would only affect the startup time, and if the startup time of your application is fine, there's no point caring.

    [quote:20r9lmez]When I add a sprite to Construct it converts it to a PNG, but if it's loaded in the runtime will Construct convert it to a PNG as well?

    As I said earlier, once images are saved in Construct, they stay PNG, and the runtime loads them as PNG.

    Basically, to summarise the system:

    Images in Construct are stored as PNG, given to the runtime, and then decompressed to video memory on startup or another time (depending on your texture loading settings).

    Images loaded at runtime are immediately decompressed to video memory.

    That's it!

  • As soon as you hit save in the picture editor, the image is converted to PNG and stored inside the .cap. They're also exported to the runtime as PNG. So what you use before importing it doesn't matter, although I'd recommend something lossless obviously.

  • Still makes me wonder why the last pixels are clipped. I've been under the assumption that no matter what size the sprite/texture is it's dimensions are always stretched to the power of two in the GPU memory.

    Maybe some engines do this, but Construct does not, it places the texture unscaled with transparent edges on the smallest power-of-two texture that can accomodate it.

    You could also get into the habit of using .dds files

    Construct does not use DDS internally, so the file format you use won't affect this.

    As for your original problem, the technical reason the clipping of 1 pixel occurs is this:

    Construct supports scrolling to floating-point co-ordinates (this will happen centering the window on almost any moving sprite) for optimal display. It makes scrolling and motion very smooth. However, it causes a problem for tiling.

    Graphics cards can natively tile any power-of-two texture seamlessly, a bit like using a mesh distort on a sprite with UV co-ordinates above 1. The problem is when the texture is not power-of-two, Construct stores it on a power-of-two texture with transparent edges, so tiling that would have transparent areas between each tile - not very useful.

    So in that mode, Tiled Background resorts to an alternative tiling system which basically amounts to drawing separate sprites in a grid. However, when you scroll to a floating-point co-ordinate, you end up drawing these tiles at floating-point offsets, which overlap, but due to the way they blend, they have one pixel seams between them. There were a lot of complaints about the seaming - it doesn't look good at all. So as a fix, pretty much the only thing that I could do was move the tiling back one pixel, so the next tile covers up the seam. But you lose one pixel to the bottom and to the right of your tile. As far as I remember, if you stretch up an image to fill the power-of-two texture and tile that, it blurs the actual texture, so isn't any good either. Basically, there's no way to perfectly tile non power-of-two textures with floating point scrolling.

    Note the layout editor does not support floating-point scrolling, so you always see it perfectly here. (it should probably preview the same as it'll appear in the runtime though, I guess that's a bug)

    The only way around it is to use power-of-two textures. I can't even make it tile perfectly if you disable floating point scrolling by forcing scrolling to round(x) and round(y) - then applications which do scroll smoothly will see their tiles jittering by one pixel when it hits an integer scroll position.

    So yeah, it's complicated. But basically you can totally side-step all the problems, just by using a power-of-two texture, as is documented (although maybe the object itself should tell you). Those tile perfectly on the GPU. So, there's your explanation, and your fix

  • I don't think anyone's started an XML plugin yet. So feel free to start one. Post any questions you have here and I'll try to answer them all!

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads