Search found 4835 matches

by bartbes
Sat Nov 25, 2017 1:06 pm
Forum: Support and Development
Topic: Strange bug makes me suspicious of video library
Replies: 1
Views: 1816

Re: Strange bug makes me suspicious of video library

It's definitely possible there are bugs, it's a fairly new and complex beast, but I don't think it's that bad. Can you share some (preferably minimal) example code which demonstrates this issue?
by bartbes
Fri Nov 24, 2017 4:58 pm
Forum: Support and Development
Topic: demand() on channel from errorneous thread -> deadlock
Replies: 11
Views: 5349

Re: demand() on channel from errorneous thread -> deadlock

Is it possible, for a future version, to implement a mechanism for reporting thread errors that works like an exception instead of an event? No, because lua itself isn't thread-safe. There is no way to interrupt the main thread, so it has to poll, in this case via the event loop. Or maybe a way to ...
by bartbes
Fri Nov 24, 2017 1:35 pm
Forum: Support and Development
Topic: demand() on channel from errorneous thread -> deadlock
Replies: 11
Views: 5349

Re: demand() on channel from errorneous thread -> deadlock

Yeah, the only way around that is to load the thread contents later, I guess. Something like: local channel, contents = ... local ok, err = pcall(function() loadstring(contents)(channel) end) if not ok then channel:supply{error = true, data = err} end (Or pass a filename and call love.filesystem.loa...
by bartbes
Thu Nov 23, 2017 9:03 pm
Forum: Support and Development
Topic: demand() on channel from errorneous thread -> deadlock
Replies: 11
Views: 5349

Re: demand() on channel from errorneous thread -> deadlock

It's already been lifted for 0.11.0, and it will error if it detects cycles (instead of go into an infinite loop/overflow the stack). It's still a very basic copying mechanism though, and I wouldn't be surprised if some lua serializers outperform it.
by bartbes
Thu Nov 23, 2017 6:59 pm
Forum: Support and Development
Topic: demand() on channel from errorneous thread -> deadlock
Replies: 11
Views: 5349

Re: demand() on channel from errorneous thread -> deadlock

Because of a bug you can actually push nested tables (though it won't detect cycles) in 0.10.2. Otherwise, if the returned data can be arbitrary you can really only do a double push (or use a second channel). If the data is a specific type you can return an error directly, or nil, or something like ...
by bartbes
Thu Nov 23, 2017 3:56 pm
Forum: Support and Development
Topic: demand() on channel from errorneous thread -> deadlock
Replies: 11
Views: 5349

Re: demand() on channel from errorneous thread -> deadlock

I believe this is because the main thread reaches channel:demand() before the thread encounters the error. The main thread is now blocked, waiting for data on the channel; the thread can't supply data because of the error; love.threaderror doesn't get called because the main thread is blocked. Tota...
by bartbes
Tue Nov 21, 2017 11:09 am
Forum: Support and Development
Topic: multiple function arguments
Replies: 4
Views: 3262

Re: multiple function arguments

The problem is that you can only have varargs as the last argument(s). So if you rewrite your function like this, it won't error: function poly(color, ...) local edges = {...} end (Note that color is already a local, as it is an argument, so 'local color = color' doesn't actually do anything useful.)
by bartbes
Mon Nov 20, 2017 10:27 pm
Forum: Support and Development
Topic: Integrate Torch7 into LÖVE?
Replies: 3
Views: 2952

Re: Integrate Torch7 into LÖVE?

I don't think you need to compile torch into love, just stick the dll (compiled for lua 5.1) next to the exe and require torch.
by bartbes
Mon Nov 20, 2017 10:02 am
Forum: Support and Development
Topic: [Linux - KDE neon]LOVE Does Strange Things to KWin
Replies: 4
Views: 5454

Re: [Linux - KDE neon]LOVE Does Strange Things to KWin

I did some googling and came across this forum post. Is your compositor backend set to OpenGL 2.0, and if so, can you try setting it to OpenGL 3.1?
by bartbes
Sun Nov 19, 2017 10:02 pm
Forum: Support and Development
Topic: [Linux - KDE neon]LOVE Does Strange Things to KWin
Replies: 4
Views: 5454

Re: [Linux - KDE neon]LOVE Does Strange Things to KWin

The shadows for my KDE panels disappear, [...] and it looks like some windows have a black square being rendered behind them. So it sounds like it's your compositor that breaks, somehow. In case you don't know, the compositor is the part of the (x11) graphics stack that implements transparent windo...