Search found 72 matches
- Fri Nov 13, 2015 12:28 am
- Forum: Support and Development
- Topic: [Solved] Composite layers?
- Replies: 7
- Views: 4318
Re: [Solved] Composite layers?
Ah cool. I took a look over your code and it looked really good, though you should send the canvas to the shader immediately after you set the shader. Currently the blendmode is being set a frame late. You can easily see this if you insert a love.timer.sleep(0.5)
- Thu Nov 12, 2015 7:18 pm
- Forum: Support and Development
- Topic: How to prevent scaling in Windows?
- Replies: 4
- Views: 2856
Re: How to prevent scaling in Windows?
High DPI scaling for Windows/Linux is supported in Love2d or more accurately it is not in the underlying library SDL. So you either have to turn off scaling in windows or normal/exclusive fullscreen might give you the full resolution. (With the obvious problem that you're forced to use fullscreen)
- Thu Nov 12, 2015 2:18 pm
- Forum: Support and Development
- Topic: [Solved] Composite layers?
- Replies: 7
- Views: 4318
Re: [Solved] Composite layers?
I think your formula to overlay blending might be wrong. I've attached my code so you could take a look at that. :awesome: (I did some pretty stupid things in there though. Like placing where the image is drawn inside the shader. But the formulas for blending is correct.) --[[ The MIT License (MIT) ...
- Thu Nov 12, 2015 12:16 am
- Forum: Support and Development
- Topic: [Solved] Composite layers?
- Replies: 7
- Views: 4318
Re: Composite layers?
I've done something similar to this myself. And it seems completely impossible to access what you are drawing to. (I have no idea why. Could anyone explain why this limitation exist?) So I did the same as you. Drawing to a canvas and sending the canvas to the shader then drawing a blendmode image. W...
- Mon Nov 09, 2015 8:53 pm
- Forum: Support and Development
- Topic: Resizing ImageData
- Replies: 3
- Views: 3226
Re: Resizing ImageData
Needed something similar myself so I wrote it now :awesome: Now the down-sampling is rather poor. But it works. local function createThumbnail(fileName,scale) scale = scale or 1 local img = love.graphics.newImage(fileName) local canvas = love.graphics.newCanvas(img:getWidth()*scale , img:getHeight()...
- Tue Nov 03, 2015 1:26 pm
- Forum: Support and Development
- Topic: How to do a functional and simple fullscreen system?
- Replies: 7
- Views: 4813
Re: How to do a functional and simple fullscreen system?
That might be Windows that is messing with you. It looks fine on this mac I tried it on both fullscreen and windowed. You can try to turn off vsync and see how that goes. Just add vsync = false to love.window.setMode() and you FPS should be somewhere between 200-1000FPS. If it stays in the 60-100FPS...
- Mon Nov 02, 2015 9:33 pm
- Forum: Support and Development
- Topic: How to do a functional and simple fullscreen system?
- Replies: 7
- Views: 4813
Re: How to do a functional and simple fullscreen system?
Does "local canvasW,canvasH = yourCanvasName:getDimensions()" set the canvas width and height? I can't find anything on the wiki about setting up width or height of canvases. Are screenW and screenH already defined variables of my display resolution like 1366x768? Does the 2nd line define...
- Mon Nov 02, 2015 6:01 pm
- Forum: Support and Development
- Topic: How to do a functional and simple fullscreen system?
- Replies: 7
- Views: 4813
Re: How to do a functional and simple fullscreen system?
Something like this should do it (You were close). Untested though.
Code: Select all
-- Dumb math was here, look at my next post
- Tue Oct 20, 2015 11:32 pm
- Forum: Support and Development
- Topic: Applying a textured overlay
- Replies: 6
- Views: 2953
Re: Applying a textured overlay
I did something like this for my ludum dare 32
http://evine.itch.io/iamtrojanhorse
I basically just have a large "image/texture" drawn over the entire screen.
The texture was converted to black/white and then converted that to black/transparent.
http://evine.itch.io/iamtrojanhorse
I basically just have a large "image/texture" drawn over the entire screen.
The texture was converted to black/white and then converted that to black/transparent.
- Mon Sep 28, 2015 8:05 pm
- Forum: Support and Development
- Topic: Audio Looping
- Replies: 2
- Views: 1258