Search found 12 matches

by Jetmate
Tue May 16, 2017 9:16 pm
Forum: Support and Development
Topic: Weird graphics glitch with .5 coordinates and scaling
Replies: 2
Views: 2138

Weird graphics glitch with .5 coordinates and scaling

I'm currently working on a tile-based platformer where the levels are made up of a 50x50 grid of blocks the player can jump on. In order to provide the illusion of moving, I subtract the player's coordinates from the coordinates of every tile once each frame. I also scale the display by calling the ...
by Jetmate
Tue May 16, 2017 8:53 pm
Forum: Support and Development
Topic: Love speed comparison
Replies: 5
Views: 7194

Re: Love speed comparison

You're right that vsync causes the frame delays - I turned it off and the fps instantly jumped. After doing some more tests, I think I've found an explanation for the initial speed loss: the numerous modules that love loads in the beginning. I turned them off and the speed increased to meet Pygame. ...
by Jetmate
Tue May 16, 2017 8:15 pm
Forum: Support and Development
Topic: Love speed comparison
Replies: 5
Views: 7194

Love speed comparison

I recently conducted a speed test between love and Pygame, which runs on Python and is known for being very slow. The test involved drawing a variable number of small rectangles every frame for 100 frames, and then finding the average of the times it took to draw the rectangles every frame. Here are...
by Jetmate
Sat May 13, 2017 2:57 pm
Forum: Support and Development
Topic: [SOLVED] Drawing shapes on an image
Replies: 6
Views: 3872

Re: Drawing shapes on an image

Generally, then, what's the advantages to using images over canvases? Is it just easier because you can quickly create images from a file?
by Jetmate
Sat May 13, 2017 2:03 pm
Forum: Support and Development
Topic: [SOLVED] Drawing shapes on an image
Replies: 6
Views: 3872

Re: Drawing shapes on an image

Is the process of creating a canvas, setting it as active, drawing on it, and then setting it as inactive generally considered slow? Instead of using it as a texture to draw with, is it faster to first convert it to an image, and then draw that image?
by Jetmate
Sat May 13, 2017 2:39 am
Forum: Support and Development
Topic: [SOLVED] Drawing shapes on an image
Replies: 6
Views: 3872

[SOLVED] Drawing shapes on an image

Pygame, which is the previous game API that I used, had an option to draw shapes on another image or canvas - from what I can tell, love only allows those shapes to be drawn directly to the screen. Is there any way around this? Thank you.
by Jetmate
Mon May 08, 2017 11:36 pm
Forum: Support and Development
Topic: [SOLVED] Is the way Love handles sprites inefficient?
Replies: 17
Views: 12557

Re: Is the way Love handles sprites inefficient?

Rendering an axis-aligned image using the GPU is just as fast or slow as rendering an arbitrarily oriented one. This is not specific to love, but it is something love's APIs take advantage of. Rotating an image is not a bottleneck. So even if I only have two configurations for a sprite that I ever ...
by Jetmate
Mon May 08, 2017 8:14 pm
Forum: Support and Development
Topic: [SOLVED] Is the way Love handles sprites inefficient?
Replies: 17
Views: 12557

Re: Is the way Love handles sprites inefficient?

Images aren't immutable, just as GL textures aren't, but you try to not really modify them because then you'd have to send the whole texture again. So does that mean that every time I apply an operation to a sprite (in another API, such as a rotation), I'm not actually modifying that sprite, but ju...
by Jetmate
Mon May 08, 2017 3:17 am
Forum: Support and Development
Topic: [SOLVED] Is the way Love handles sprites inefficient?
Replies: 17
Views: 12557

Re: Is the way Love handles sprites inefficient?

So, from what I understand, there is no way to take a central spritesheet and then copy specific parts of it into new images? Quads are the only option? Just as a side question - images in Love are immutable, right? Meaning if I have a bunch of objects that each have a variable that holds their spri...
by Jetmate
Mon May 08, 2017 12:45 am
Forum: Support and Development
Topic: [SOLVED] Is the way Love handles sprites inefficient?
Replies: 17
Views: 12557

Re: Is the way Love handles sprites inefficient?

What specific graphics transformation routines are you talking about? The wiki only lists functions for rotation/scaling/etc the entire screen, but not specific textures.