11.0 bugs

General discussion about LÖVE, Lua, game development, puns, and unicorns.
User avatar
pgimeno
Party member
Posts: 3541
Joined: Sun Oct 18, 2015 2:58 pm

11.0 bugs

Post by pgimeno »

  • I was taking a look at the source and found this snippet in wrap_Graphics.cpp:

    Code: Select all

    if (targets.colors.back().canvas->getTextureType() != TEXTURE_2D)
      return luaL_error(L, "The table-of-tables variant of setCanvas must be used with non-2D Canvases.");
    
    By my reading, the error message should either be "can't be used with non-2D..." or "must be used with 2D...".

  • love.image.newImageData(1, 1, 'abcd') worked in 0.10 (creating an rgba8 image with the given data); in 11.0 it's triggering "Invalid pixel format: abcd" - however love.image.newImageData(1, 1, 'rgba8', 'abcd') works as expected. Is that just a documentation issue? Or was the intention to default to 'rgba8' like 0.10 did, when using a 3-parameter version?
User avatar
slime
Solid Snayke
Posts: 3129
Joined: Mon Aug 23, 2010 6:45 am
Location: Nova Scotia, Canada
Contact:

Re: 11.0 bugs

Post by slime »

pgimeno wrote: Wed Apr 04, 2018 2:59 pm By my reading, the error message should either be "can't be used with non-2D..." or "must be used with 2D...".
The error is trying to say that non-2D canvases must use a different variant of the function than setCanvas(canvas, ...) or setCanvas{canvas, ...} (they must use a new table-of-tables variant).
pgimeno wrote: Wed Apr 04, 2018 2:59 pm love.image.newImageData(1, 1, 'abcd') worked in 0.10 (creating an rgba8 image with the given data); in 11.0 it's triggering "Invalid pixel format: abcd" - however love.image.newImageData(1, 1, 'rgba8', 'abcd') works as expected. Is that just a documentation issue?
Yes, the old 3 parameter version is removed. The new function definition is newImageData(width, height [, format [, rawbytes]]) instead of newImageData(width, height [, rawbytes]).
User avatar
Davidobot
Party member
Posts: 1226
Joined: Sat Mar 31, 2012 5:18 am
Location: Oxford, UK
Contact:

Re: 11.0 bugs

Post by Davidobot »

The changelog has the following line:

Code: Select all

Added Shader:send(matrixname, is_column_major, matrix, ...) which specifies how to interpret the matrix table arguments.
But the page for Shader:send only has this version:

Code: Select all

Shader:send( name, data, matrixlayout, offset, size )
Further, changing the matrixlayout between "row" and "column" seems to have no effect.

I also think that the change from matrices being column-major to row-major should be listed in the changelog.
PM me on here or elsewhere if you'd like to discuss porting your game to Nintendo Switch via mazette!
personal page and a raycaster
User avatar
pgimeno
Party member
Posts: 3541
Joined: Sun Oct 18, 2015 2:58 pm

Re: 11.0 bugs

Post by pgimeno »

@slime:

Thanks for the explanation on the error message. It's clear now, though I wonder if it will mislead more people.

About newImageData, I've edited the wiki accordingly. I may have screwed up the order, not sure.

To hopefully prevent it from getting lost in the other thread, and since I can't use the issue tracker submit form in BitBucket, I'll add it here too: when building as static, pthread is missing from the link line.

@Davidobot: Yeah, I was confused by that too. Note that the variant listed in the docs actually requires a Data object, not a table. No idea how to generate that object (maybe from a Transform? but there's no Transform:getData() so no idea), or why it's useful.
User avatar
MarvelME
Prole
Posts: 13
Joined: Wed Oct 26, 2016 4:02 pm
Location: Ukraine
Contact:

Re: 11.0 bugs

Post by MarvelME »

Console stopped working:

Code: Select all

c:\Gamedev\Love\RL2\RL2>"c:\Program Files\LOVE\lovec.exe" c:\Gamedev\Love\RL2\RL2 s
Error: [string "boot.lua"]:385: Could not create console.
stack traceback:
        [string "boot.lua"]:637: in function <[string "boot.lua"]:633>
        [C]: in function '_openConsole'
        [string "boot.lua"]:385: in function <[string "boot.lua"]:311>
        [C]: in function 'xpcall'
        [string "boot.lua"]:645: in function <[string "boot.lua"]:639>
        [C]: in function 'xpcall'

Win10 x64

.. but its not a issue for me, changed lovec to love, ait it just prints to console
User avatar
SiENcE
Party member
Posts: 792
Joined: Thu Jul 24, 2008 2:25 pm
Location: Berlin/Germany
Contact:

Re: 11.0 bugs

Post by SiENcE »

It's a hard crash.

Samples attached (it's not from me, it was earlier shared in the forum).

When i comment the following line out, everything works.

Code: Select all

shader2 = love.graphics.newShader("shader2.glsl")
Attachments
Shockwave_working_love110.love
(1.1 MiB) Downloaded 386 times
Shockwave.love
(1.1 MiB) Downloaded 402 times
crash_love110.jpg
crash_love110.jpg (39.93 KiB) Viewed 15778 times
Last edited by SiENcE on Thu Apr 05, 2018 1:43 pm, edited 2 times in total.
azoyan
Prole
Posts: 25
Joined: Wed Dec 27, 2017 5:19 pm

Re: 11.0 bugs

Post by azoyan »

Where is love.audio.setEffect documentation? I see only https://love2d.org/wiki/Source:setEffect documentation.
User avatar
SiENcE
Party member
Posts: 792
Joined: Thu Jul 24, 2008 2:25 pm
Location: Berlin/Germany
Contact:

Re: 11.0 bugs

Post by SiENcE »

azoyan wrote: Thu Apr 05, 2018 1:34 pm Where is love.audio.setEffect documentation? I see only https://love2d.org/wiki/Source:setEffect documentation.
I think it's no bug... but this is all i can find: https://love2d.org/wiki/Effect_Constant ... Candidates

Also: https://love2d.org/irclogs/love-2017-06-21.log
User avatar
zorg
Party member
Posts: 3435
Joined: Thu Dec 13, 2012 2:55 pm
Location: Absurdistan, Hungary
Contact:

Re: 11.0 bugs

Post by zorg »

azoyan wrote: Thu Apr 05, 2018 1:34 pm Where is love.audio.setEffect documentation? I see only https://love2d.org/wiki/Source:setEffect documentation.
Someone still needs to write that for the wiki i guess.
Me and my stuff :3True Neutral Aspirant. Why, yes, i do indeed enjoy sarcastically correcting others when they make the most blatant of spelling mistakes. No bullying or trolling the innocent tho.
User avatar
Ref
Party member
Posts: 702
Joined: Wed May 02, 2012 11:05 pm

Re: 11.0 bugs

Post by Ref »

Is there no direct way to get imagedata from an image in Love 11?
The only way I've found is to draw the image to a canvas and then get the imagedata from the canvas or to reload the image from a file as imagedata.
Post Reply

Who is online

Users browsing this forum: Google [Bot] and 23 guests