Difference between revisions of "12.0"

m (Fix HTTPS module link)
m
 
(31 intermediate revisions by 4 users not shown)
Line 1: Line 1:
 
{{notice|The information on this page may not be accurate or up to date due to the information pertaining to a version that is currently in development.}}
 
{{notice|The information on this page may not be accurate or up to date due to the information pertaining to a version that is currently in development.}}
  
The codename for LÖVE 12.0 is TBD. It is currently '''<span style="color:#ff0000;">not released</span>'''.
+
The codename for LÖVE 12.0 is '''Bestest Friend'''. It is currently '''<span style="color:#ff0000;">not released</span>'''.
  
== Changes from [[11.4]] ==
+
== Changes from [[11.5]] ==
  
 
=== Additions ===
 
=== Additions ===
 
'''General'''
 
'''General'''
 
* Added support for launching a specific .lua file as the main file.
 
* Added support for launching a specific .lua file as the main file.
 +
* Added basic usage instructions printed to the console when '--help' is used as a command-line parameter, and when the no-game screen is run.
 +
* Added an option to add LÖVE to the user's command-line path in the Windows installer.
 
* Added [[love.parsedGameArguments]] and [[love.rawGameArguments]] tables, in the main thread.
 
* Added [[love.parsedGameArguments]] and [[love.rawGameArguments]] tables, in the main thread.
 
* Added [[love.markDeprecated]].
 
* Added [[love.markDeprecated]].
 
* Added [[love.event.restart|love.event.restart(optionalvalue)]]. A new [[love.restart]] field will contain the value after restarting.
 
* Added [[love.event.restart|love.event.restart(optionalvalue)]]. A new [[love.restart]] field will contain the value after restarting.
 +
* Added an optional wait timeout parameter to [[love.event.pump]].
 
* Added [[love.system.getPreferredLocales]].
 
* Added [[love.system.getPreferredLocales]].
 
* Added [[love.localechanged]] callback.
 
* Added [[love.localechanged]] callback.
* Added [[love.dropbegan]] and [[love.dropcompleted]] callbacks.
+
* Added [[love.dropbegan]], [[love.dropmoved]], and [[love.dropcompleted]] callbacks.
* Added t.highdpi startup flag in [[love.conf]], replacing t.window.highdpi and the highdpi flag of [[love.window.setMode]].
+
* Added drop position parameters to [[love.filedropped]] and [[love.directorydropped]].
* Added support for highdpi mode in Windows.
 
 
* Added [[lua-https|HTTPS]] Lua module.
 
* Added [[lua-https|HTTPS]] Lua module.
 +
* Added variants of enet's [[enet.peer:send|peer:send]] and [[enet.host:broadcast|host:broadcast]] methods that take light userdata and size parameters.
 +
* Added support in love [[Object]]s for Lua 5.4's '<toclose>' syntax, when love is compiled with Lua 5.4.
 +
 +
 +
''' Data '''
 +
* Added [[Data]] methods for getting number values.
 +
* Added [[ByteData]] methods for setting number values.
 +
* Added optional byte offset and size parameters to [[Data:getString]].
 +
* Added [[ByteData:setString]].
 +
* Added a variant of [[love.data.pack]] which takes an existing [[ByteData]] object.
  
  
Line 25: Line 37:
 
* Added an optional load mode parameter to [[love.filesystem.load]] to only allow binary chunks, text chunks, or both.
 
* Added an optional load mode parameter to [[love.filesystem.load]] to only allow binary chunks, text chunks, or both.
 
* Added [[love.filesystem.openFile]] (replaces [[love.filesystem.newFile]]).
 
* Added [[love.filesystem.openFile]] (replaces [[love.filesystem.newFile]]).
 +
* Added [[love.filesystem.openNativeFile]].
  
  
Line 36: Line 49:
  
 
''' Input '''
 
''' Input '''
 +
* Added a [[love.sensor]] module, for getting data from device sensors such as an accelerometer or gyroscope.
 +
* Added [[love.sensorupdated]] callback.
 +
* Added [[love.joysticksensorupdated]] callback.
 +
* Added [[Joystick:hasSensor]].
 +
* Added [[Joystick:setSensorEnabled]] and [[Joystick:isSensorEnabled]].
 +
* Added [[Joystick:getSensorData]].
 
* Added [[Joystick:setPlayerIndex]] and [[Joystick:getPlayerIndex]].
 
* Added [[Joystick:setPlayerIndex]] and [[Joystick:getPlayerIndex]].
 +
* Added [[Joystick:getJoystickType]].
 
* Added [[Joystick:getGamepadType]].
 
* Added [[Joystick:getGamepadType]].
 
* Added new [[GamepadButton|Gamepad API buttons]]: "misc1", "paddle1", "paddle2", "paddle3", "paddle4". and "touchpad".
 
* Added new [[GamepadButton|Gamepad API buttons]]: "misc1", "paddle1", "paddle2", "paddle3", "paddle4". and "touchpad".
 
* Added [[love.keyboard.isModifierActive]].
 
* Added [[love.keyboard.isModifierActive]].
 +
* Added direction enum parameter to [[love.wheelmoved]].
 +
* Added [[love.mouse.getGlobalPosition]].
 +
* Added variant of [[love.mouse.newCursor]] which takes an array of image paths, for handling multiple DPI scales.
 +
* Added [[TouchDeviceType]] enum and 'ismouse' boolean parameter to [[love.touchpressed]], [[love.touchmoved]], and [[love.touchreleased]].
 +
* Added [[love.touch.getDeviceType]].
 +
* Added [[love.touch.isMouse]].
 +
* Added optional touch device type filter parameter to [[love.touch.getTouches]].
 +
* Added 't.trackpadtouch' boolean to love.conf. Trackpad touch events will not be generated unless it's enabled.
  
  
Line 47: Line 75:
  
 
''' Physics '''
 
''' Physics '''
* Added [[World:getFixturesInArea]].
+
* Added [[World:rayCastAny]] and [[World:rayCastClosest]].
 +
* Added [[World:getShapesInArea]].
 +
* Added [[World:queryShapesInArea]] (replaces [[World:queryBoundingBox]]).
 +
* Added [[Body:getShapes]] (replaces [[Body:getFixtures]]).
 +
* Added [[Body:getShape]] convenience method.
 +
* Added [[Contact:getShapes]] (replaces [[Contact:getFixtures]]).
 +
* Added [[Body:hasCustomMassData]].
 +
* Added convenience functions for creating a [[Body]] and [[Shape]] together:
 +
** Added [[love.physics.newCircleBody]].
 +
** Added [[love.physics.newRectangleBody]].
 +
** Added [[love.physics.newPolygonBody]].
 +
** Added [[love.physics.newEdgeBody]].
 +
** Added [[love.physics.newChainBody]].
 +
* Any joint that used to use spring-dampers now use stiffness and damping. The following functions have been added to support the old behaviour.
 +
** Added [[love.physics.computeLinearStiffness]].
 +
** Added [[love.physics.computeLinearFrequency]].
 +
** Added [[love.physics.computeAngularStiffness]].
 +
** Added [[love.physics.computeAngularFrequency]].
 +
 
 +
 
 +
''' Window '''
 +
* Added t.highdpi startup flag in [[love.conf]], replacing t.window.highdpi and the highdpi flag of [[love.window.setMode]].
 +
* Added support for highdpi mode in Windows.
 +
* Added [[love.window.showFileDialog]].
 +
* Added [[love.window.focus]].
 +
* Added [[love.window.getPointer]].
 +
* Added [[love.exposed]] and [[love.occluded]] callbacks.
  
  
Line 54: Line 108:
 
* Added a Vulkan backend to [[love.graphics]], available on Windows, Linux, and Android 7+.
 
* Added a Vulkan backend to [[love.graphics]], available on Windows, Linux, and Android 7+.
 
* Added '--renderers a,b,c' and '--excluderenderers a,b,c' command line arguments.
 
* Added '--renderers a,b,c' and '--excluderenderers a,b,c' command line arguments.
* Added t.renderers and t.excluderenderers [[love.conf]] options.
+
* Added t.graphics.renderers and t.graphics.excluderenderers [[love.conf]] options.
 +
* Added t.graphics.lowpower [[love.conf]] option.
 +
 
 +
 
 
* Added per-shader opt in support for the GLSL 4.30 (desktop) and GLSL ES 3.20 (mobile) shading languages, via <code>#pragma language glsl4</code>.
 
* Added per-shader opt in support for the GLSL 4.30 (desktop) and GLSL ES 3.20 (mobile) shading languages, via <code>#pragma language glsl4</code>.
 +
* Added new lower level 'vertexmain' and 'pixelmain' shader entry points.
 +
* Added ability to set point size within a vertex shader by setting the 'love_PointSize' variable.
 +
* Added [[Shader|Compute Shader]] support via [[love.graphics.newComputeShader]] and a new 'computemain' shader entry point.
 +
* Added [[love.graphics.dispatchThreadgroups]] and [[love.graphics.dispatchIndirect]] for running compute shaders.
 +
* Added [[Shader:hasStage]].
 +
* Added [[love.graphics.drawFromShader]].
 +
* Added [[love.graphics.drawFromShaderIndirect]].
 +
* Added [[love.graphics.drawIndirect]].
 +
 +
 
* Added [[love.graphics.newTexture]]. [[love.graphics.newImage|newImage]] and [[love.graphics.newCanvas|newCanvas]] still exist as convenience constructor functions.
 
* Added [[love.graphics.newTexture]]. [[love.graphics.newImage|newImage]] and [[love.graphics.newCanvas|newCanvas]] still exist as convenience constructor functions.
 +
* Added optional 'mipmapcount' field to the settings table in [[love.graphics.newTexture]]/[[love.graphics.newImage|newImage]]/[[love.graphics.newCanvas|newCanvas]].
 +
* Added optional 'computewrite' boolean field to the settings table in [[love.graphics.newTexture]]/[[love.graphics.newImage|newImage]]/[[love.graphics.newCanvas|newCanvas]].
 
* Added [[love.graphics.getTextureFormats]], which replaces [[love.graphics.getImageFormats|getImageFormats]] and [[love.graphics.getCanvasFormats|getCanvasFormats]].
 
* Added [[love.graphics.getTextureFormats]], which replaces [[love.graphics.getImageFormats|getImageFormats]] and [[love.graphics.getCanvasFormats|getCanvasFormats]].
 +
* Added [[Texture:isCanvas]] and [[Texture:isComputeWritable]].
 +
* Added [[Texture:isFormatLinear]], [[Texture:getMSAA]], [[Texture:generateMipmaps]], [[Texture:replacePixels]], and [[Texture:renderTo]] (moved from old Canvas and Image subclasses).
 +
* Added support for [[CompressedImageData]] to [[Texture:replacePixels]].
 +
* Added [[love.graphics.newTextureView]].
 +
* Added optional 'viewformats' field to the settings table in [[Texture]] constructors.
 +
* Added [[Texture:getViewFormats]].
 
* Added integer [[PixelFormat|pixel formats]] for [[Texture]]s and [[ImageData]].
 
* Added integer [[PixelFormat|pixel formats]] for [[Texture]]s and [[ImageData]].
* Added Graphics [[Buffer]] objects, including vertex, index, texel, and shader storage buffers.
+
* Added explicit sRGB format enums for compressed texture [[PixelFormat|pixel formats]].
 +
* Added [[ImageData:setLinear]], [[CompressedImageData:setLinear]], [[ImageData:isLinear]], and [[CompressedImageData:isLinear]].
 +
 
 +
 
 +
* Added [[GraphicsBuffer|Graphics Buffer]] objects, including vertex, index, texel, shader storage, and indirect draw/dispatch argument buffers.
 
* Added [[love.graphics.copyBuffer]], [[love.graphics.copyBufferToTexture|copyBufferToTexture]], and [[love.graphics.copyTextureToBuffer|copyTextureToBuffer]].
 
* Added [[love.graphics.copyBuffer]], [[love.graphics.copyBufferToTexture|copyBufferToTexture]], and [[love.graphics.copyTextureToBuffer|copyTextureToBuffer]].
* Added APIs for interacting with the [[Buffer]] objects owned by [[Mesh]]es.
+
* Added APIs for interacting with the [[GraphicsBuffer|Buffer]] objects owned by [[Mesh]]es.
 +
* Added variants of [[love.graphics.newMesh]] to construct a [[Mesh]] from existing [[GraphicsBuffer|Buffer]]s.
 
* Added [[Mesh:getAttachedAttributes]].
 
* Added [[Mesh:getAttachedAttributes]].
 +
* Added an optional start array index parameter to [[Mesh:attachAttribute]].
 +
* Added variants of [[Mesh:attachAttribute]], [[Mesh:setAttributeEnabled]], and [[Mesh:isAttributeEnabled]] which take vertex attribute location numbers instead of names.
 
* Added integer [[BufferDataFormat|buffer data formats]].
 
* Added integer [[BufferDataFormat|buffer data formats]].
* Added [[love.graphics.readbackTexture]] and [[love.graphics.readbackTextureAsync]] (replaces [[Texture:newImageData]]).
+
* Added [[love.graphics.getQuadIndexBuffer]].
 +
* Added [[Shader:getBufferFormat]].
 +
 
 +
 
 +
* Added [[love.graphics.readbackTexture]] and [[love.graphics.readbackTextureAsync]] (replaces [[Canvas:newImageData]]).
 
* Added [[love.graphics.readbackBuffer]] and [[love.graphics.readbackBufferAsync]].
 
* Added [[love.graphics.readbackBuffer]] and [[love.graphics.readbackBufferAsync]].
 
* Added 'readback' [[BufferDataUsage|buffer data usage enum]], useful for advanced memory optimization when using [[love.graphics.readbackBuffer]].
 
* Added 'readback' [[BufferDataUsage|buffer data usage enum]], useful for advanced memory optimization when using [[love.graphics.readbackBuffer]].
* Added new lower level 'vertexmain' and 'pixelmain' shader entry points.
+
* Added debugname fields in the settings tables for [[Texture]]s, [[GraphicsBuffer|Buffer]]s, and [[Shader]]s.
* Added [[Shader|Compute Shader]] support via new 'computemain' shader entry point.
+
* Added [[Texture:getDebugName]] and [[Shader:getDebugName]].
* Added [[love.graphics.dispatchThreadgroups]] for running compute shaders.
+
 
* Added [[Shader:hasStage]].
+
 
* Added [[love.graphics.drawShaderVertices]].
 
* Added [[love.graphics.getQuadIndexBuffer]].
 
 
* Added variants of [[love.graphics.applyTransform]] and [[love.graphics.replaceTransform|replaceTransform]] which accept x,y,angle,sx,sy,ox,oy parameters.
 
* Added variants of [[love.graphics.applyTransform]] and [[love.graphics.replaceTransform|replaceTransform]] which accept x,y,angle,sx,sy,ox,oy parameters.
* Added APIs to override the default orthographic projection: [[love.graphics.setOrthoProjection]], [[love.graphics.setPerspectiveProjection|setPerspectiveProjection]], and [[love.graphics.resetProjection|resetProjection]].
+
* Added APIs to override the default orthographic projection: [[love.graphics.setProjection]] and [[love.graphics.resetProjection|resetProjection]].
* Added ability to set point size within a vertex shader by setting the 'love_PointSize' variable.
 
 
* Added [[love.graphics.setBlendState]], which gives lower level control over blend operations than [[love.graphics.setBlendMode]].
 
* Added [[love.graphics.setBlendState]], which gives lower level control over blend operations than [[love.graphics.setBlendMode]].
* Added [[love.graphics.setStencilMode]] and [[love.graphics.getStencilMode|getStencilMode]]. Replaces [[love.graphics.stencil]] as well as [[love.graphics.setStencilTest]].
+
* Added high level [[love.graphics.setStencilMode]] and [[love.graphics.getStencilMode|getStencilMode]] functions. Replaces [[love.graphics.stencil]] and [[love.graphics.setStencilTest]].
 +
* Added lower level [[love.graphics.setStencilState]] and [[love.graphics.getStencilState]] functions.
 
* Added a variant of [[love.graphics.setColorMask]] which accepts a single boolean.
 
* Added a variant of [[love.graphics.setColorMask]] which accepts a single boolean.
 
* Added new 'clampone' [[WrapMode]].
 
* Added new 'clampone' [[WrapMode]].
 +
* Added 'clampone', 'texelbuffer', 'indexbuffer32bit', 'mipmaprange', and 'indirectdraw' [[GraphicsFeature]] enums.
 +
* Added 'copybuffer', 'copybuffertotexture', 'copytexturetobuffer', and 'copyrendertargettobuffer' [[GraphicsFeature]] enums.
 +
* Added 'buffers' and 'buffermemory' fields to the table returned by [[love.graphics.getStats]].
 +
* Added initial support for right-to-left (RTL) text when using TrueType and OpenType fonts.
 
* Added a variant of [[Font:getWidth]] which takes a codepoint number argument.
 
* Added a variant of [[Font:getWidth]] which takes a codepoint number argument.
 +
* Added optional settings table variants for [[love.graphics.newFont]], [[love.font.newRasterizer]], and [[love.font.newTrueTypeRasterizer]].
 +
* Added [[love.graphics.newTextBatch]] (renamed from [[love.graphics.newText]]).
 
* Added support for saving .exr image files via [[ImageData:encode]].
 
* Added support for saving .exr image files via [[ImageData:encode]].
  
  
 
=== Changes ===
 
=== Changes ===
 +
* Changed the primary build system for Linux to CMake instead of autotools.
 +
* Changed the minimum runtime macOS version to 10.15.
 +
* Changed the minimum runtime iOS version to 13.0.
 +
* Changed the minimum runtime Windows version to Windows 7 SP1 (64 bit).
 +
* Changed the minimum runtime graphics requirement to OpenGL 3.3+, OpenGL ES 3.0+, Vulkan 1.0+, or Metal.
 +
 +
 +
* Changed [[love.physics]] Shapes and Fixtures to be combined together, in [[Shape]] objects. Separate [[Fixture]]s no longer exist.
 +
* Changed [[love.physics.newCircleShape]], [[love.physics.newRectangleShape|newRectangleShape]], [[love.physics.newPolygonShape|newPolygonShape]], [[love.physics.newEdgeShape|newEdgeShape]], and [[love.physics.newChainShape|newChainShape]] to take a [[Body]] as their first parameter.
 +
* Changed [[love.physics]] callbacks that used to take [[Fixture]] parameters to now take [[Shape]] parameters.
 +
* Changed [[Shape:setDensity]] to no longer need [[Body:resetMassData]] afterward unless the Body already has custom mass data.
 +
* Changed the behaviour of attaching a [[Shape]] to a [[Body]] to no longer reset mass data if it's been customized.
 +
* Changed [[RevoluteJoint:getMotorTorque]] and [[WheelJoint:getMotorTorque]] to take 'dt' as a parameter instead of 'inverse_dt'.
 +
 +
 +
* Changed [[love.filesystem.exists]] to no longer be deprecated.
 +
* Changed [[love.data.hash]] to have a container type parameter.
 +
* Changed the size parameter of [[love.data.newDataView]] to be optional.
 
* Changed the default font from Vera size 12 to Noto Sans size 13.
 
* Changed the default font from Vera size 12 to Noto Sans size 13.
 +
* Changed TrueType and OpenType font handling to have improved kerning and character combining support.
 +
* Changed [[love.timer.sleep]] to allow for more precise sleep durations than 1ms on platforms which support that.
 +
 +
 +
* Changed [[love.textinput]] to be disabled by default on all platforms. Use [[love.keyboard.setTextInput]] to enable it only when needed.
 +
* Changed [[love.keypressed]], [[love.keyreleased]], and [[love.keyboard.isDown]] to accept arbitrary non-ASCII keys.
 +
* Changed [[love.wheelmoved]] to use precise fractions instead of integer values for its x and y wheel movement parameters, when a mouse wheel supports precise scrolling.
 +
 +
 
* Changed the [[Texture]] class and implementation to no longer have separate [[Canvas]] and [[Image]] subclasses.
 
* Changed the [[Texture]] class and implementation to no longer have separate [[Canvas]] and [[Image]] subclasses.
 
* Changed [[Texture]]s created from image files and from [[ImageData]] to no longer hold onto a CPU copy of their pixel data after creation.
 
* Changed [[Texture]]s created from image files and from [[ImageData]] to no longer hold onto a CPU copy of their pixel data after creation.
 
* Changed [[love.graphics.newImage]] to error instead of loading a placeholder texture, when the image dimensions are too large for the system.
 
* Changed [[love.graphics.newImage]] to error instead of loading a placeholder texture, when the image dimensions are too large for the system.
 +
* Changed [[love.graphics.newImage]] to allow creating a mipmapped texture with less than the full mipmap range, instead of erroring.
 +
* Changed vertex attribute declarations in [[Shader]] code to use location indices via the <code>layout (location = #)</code> qualifier, instead of using names to match with [[Mesh]] vertex attributes.
 +
** LÖVE's default vertex attributes use location 0 for position, location 1 for texture coordinates, and location 2 for vertex colors.
 +
* Changed the vertex format used with [[love.graphics.newMesh]] to have [[BufferDataFormat|format]] and 'location' named fields.
 
* Changed [[love.graphics.newMesh]] to no longer default to the "fan" [[MeshDrawMode|Mesh draw mode]].
 
* Changed [[love.graphics.newMesh]] to no longer default to the "fan" [[MeshDrawMode|Mesh draw mode]].
 
* Changed the behaviour of [[Mesh]]es to no longer allow a vertex map or index buffer when the "fan" mesh draw mode is used.
 
* Changed the behaviour of [[Mesh]]es to no longer allow a vertex map or index buffer when the "fan" mesh draw mode is used.
* Changed [[love.window.setMode]] to no longer clear the contents of Canvases or otherwise recreate OpenGL resources.
+
* Changed love.graphics.draw(Mesh) to no longer error if the Mesh has no 'VertexPosition' attribute but does have custom vertex attributes.
 +
* Changed [[Mesh:getVertexFormat]] to use named fields, to match the new vertex format parameter setup in [[love.graphics.newMesh]].
 +
* Changed [[love.window.setMode]] to no longer clear the contents of Canvases or otherwise recreate graphics resources.
 +
* Changed [[love.graphics.rectangle]], [[love.graphics.polygon]], and other shape drawing APIs to provide texture coordinates to shaders, for filled shapes.
 
* Changed [[love.graphics.points]] to require 'love_PointSize' to be set in the vertex shader, if a custom shader is used.
 
* Changed [[love.graphics.points]] to require 'love_PointSize' to be set in the vertex shader, if a custom shader is used.
 +
* Changed [[love.graphics.setCanvas]] to always clear auto-generated temporary depth and stencil buffers when they're used.
 +
* Changed [[love.graphics.clear]] to no longer be affected by [[love.graphics.setScissor]] or [[love.graphics.setColorMask]].
 +
* Changed [[love.graphics.setDepthMode]] with the depth write parameter set to true to error if the active Canvases or window don't have a depth buffer.
 +
* Changed text layout and rendering in high-dpi situations to be more consistent across DPI scales.
 +
* Changed [[Shader]] code parsing to ignore shader entry point functions inside comments.
 +
* Changed [[Shader]] code to use GLSL3 (GLSL 3.30 or GLSL ES 3.00) by default.
 +
* Changed position output coordinate space in vertex shaders to be consistent across all graphics APIs and regardless of whether a Canvas is active.
 +
** Clip-space output is y-up. Texture contents and pixel shader coordinates are y-down.
 +
 +
 
* Changed audio file decoding to choose the most appropriate decoder based on file contents instead of the file extension.
 
* Changed audio file decoding to choose the most appropriate decoder based on file contents instead of the file extension.
 +
* Changed audio initialization to give a more descriptive error if it fails.
 
* Changed [[Video]]s to stream audio from the file instead of loading all the video file into memory for use with audio decoding.
 
* Changed [[Video]]s to stream audio from the file instead of loading all the video file into memory for use with audio decoding.
* Changed [[love.filesystem.exists]] to no longer be deprecated.
 
* Changed [[RevoluteJoint:getMotorTorque]] to take 'dt' as a parameter instead of 'inverse_dt'.
 
 
* Changed [[love.math.perlinNoise]] and [[love.math.simplexNoise]] to use higher precision numbers for its internal calculations.
 
* Changed [[love.math.perlinNoise]] and [[love.math.simplexNoise]] to use higher precision numbers for its internal calculations.
 +
* Changed the window 'depth' field in [[love.conf]] and [[love.window.setMode]]/[[love.window.updateMode|updateMode]]/[[love.window.getMode|getMode]] to be a boolean instead of a bit count number.
 +
* Changed [[love.window.isVisible]] to return false if the window is minimized.
 +
* Changed [[love.visible]] to be called when minimizing and unminimizing the window.
 +
 +
 
* Renamed 'display' field to 'displayindex' in [[love.window.setMode]]/[[love.window.updateMode|updateMode]]/[[love.window.getMode|getMode]] and [[love.conf]].
 
* Renamed 'display' field to 'displayindex' in [[love.window.setMode]]/[[love.window.updateMode|updateMode]]/[[love.window.getMode|getMode]] and [[love.conf]].
* Updated Box2D from 2.3 to 2.4.1.
+
* Renamed 'gammacorrect' field to 'graphics.gammacorrect' in [[love.conf]].
* Updated LuaSocket from 3.0-rc1 to 3.1.0.
+
* Renamed love.graphics [[Text]] objects to [[TextBatch]].
 +
 
 +
 
 +
* Updated SDL from 2.0 to 3.0.
 +
* Updated Box2D from 2.3 to [https://github.com/erincatto/box2d/blob/main/CHANGELOG.md#changes-for-version-241 2.4.1]
  
  
Line 107: Line 249:
 
* Deprecated [[love.filesystem.newFile]] (replaced by [[love.filesystem.openFile]]).
 
* Deprecated [[love.filesystem.newFile]] (replaced by [[love.filesystem.openFile]]).
 
* Deprecated [[love.math.noise]] (replaced by [[love.math.perlinNoise]] and [[love.math.simplexNoise]]).
 
* Deprecated [[love.math.noise]] (replaced by [[love.math.perlinNoise]] and [[love.math.simplexNoise]]).
 +
* Deprecated [[love.event.wait]] (replaced by wait timeout parameter in [[love.event.pump]]).
 +
* Deprecated the variants of [[love.physics.newCircleShape]], [[love.physics.newRectangleShape|newRectangleShape]], [[love.physics.newPolygonShape|newPolygonShape]], [[love.physics.newEdgeShape|newEdgeShape]], and [[love.physics.newChainShape|newChainShape]] that don't take a [[Body]] parameter.
 +
* Deprecated [[love.physics.newFixture]] (replaced by the new Shape constructor variants).
 +
* Deprecated [[Body:getFixtures]] (replaced by [[Body:getShapes]]).
 +
* Deprecated [[Contact:getFixtures]] (replaced by [[Contact:getShapes]]).
 +
* Deprecated [[World:queryBoundingBox]] (replaced by [[World:queryShapesInArea]]).
 +
* Deprecated [[ChainShape:getChildEdge]].
 +
* Deprecated the variants of [[love.data.hash]] which do not have a container type parameter.
 +
* Deprecated [[love.graphics.setNewFont]] (use [[love.graphics.newFont]] and [[love.graphics.setFont]] instead).
 +
* Deprecated [[love.graphics.newText]] (renamed to [[love.graphics.newTextBatch]]).
 
* Deprecated [[love.graphics.getImageFormats]] and [[love.graphics.getCanvasFormats]] (replaced by [[love.graphics.getTextureFormats]]).
 
* Deprecated [[love.graphics.getImageFormats]] and [[love.graphics.getCanvasFormats]] (replaced by [[love.graphics.getTextureFormats]]).
 +
* Deprecated [[love.graphics.stencil]] (replaced by [[love.graphics.setStencilMode]] or [[love.graphics.setStencilState]]).
 +
* Deprecated [[love.graphics.setStencilTest]] and [[love.graphics.getStencilTest]] (replaced by [[love.graphics.setStencilMode]] or [[love.graphics.setStencilState]]).
 +
* Deprecated the variants of [[Mesh:attachAttribute]], [[Mesh:setAttributeEnabled]], and [[Mesh:isAttributeEnabled]] which take names instead of location numbers.
 +
* Deprecated usage of <code>texture</code> as a uniform variable in [[Shader]] code, since it's a built-in function name in GLSL3.
 +
* Deprecated usage of <code>texture2D</code> function calls in [[Shader]] code. Use <code>Texel</code> or the built-in function <code>texture</code> instead.
 +
* Deprecated vertex attributes in [[Shader]] code when they aren't tagged with a <code>layout (location = #)</code> qualifier.
 +
* Deprecated [[love.window.close]].
 
* Deprecated t.window.highdpi in [[love.conf]] and the highdpi flag of [[love.window.setMode]] (replaced by t.highdpi in [[love.conf]]).
 
* Deprecated t.window.highdpi in [[love.conf]] and the highdpi flag of [[love.window.setMode]] (replaced by t.highdpi in [[love.conf]]).
* Deprecated the variants of [[Mesh:attachAttribute]] and [[SpriteBatch:attachAttribute]] which accept a [[Mesh]] (replaced by variants which accept a [[Buffer]]).
+
* Deprecated the variants of [[Mesh:attachAttribute]] and [[SpriteBatch:attachAttribute]] which accept a [[Mesh]] (replaced by variants which accept a [[GraphicsBuffer]]).
* Deprecated [[Texture:newImageData]] (replaced by [[love.graphics.readbackTexture]]).
+
* Deprecated [[Canvas:newImageData]] (replaced by [[love.graphics.readbackTexture]]).
  
  
 
=== Removals ===
 
=== Removals ===
 +
* Removed 32 bit Windows support for official builds.
 +
* Removed the <code>t.accelerometerjoystick</code> [[love.conf]] flag (replaced by the [[love.sensor]] module).
 +
* Removed [[Fixture]] objects. All methods previously in Fixtures are now available in [[Shape]]s.
 +
* Removed distinct [[DroppedFile]] subtype.
 
* Removed the variant of [[SpriteBatch:setColor]]() which turns off all previously set colors.
 
* Removed the variant of [[SpriteBatch:setColor]]() which turns off all previously set colors.
* Removed the no-argument variant of [[love.graphics.setColorMask]].
+
* Removed the <code>NormalMatrix</code> [[Shader_Variables|Shader uniform variable]].
* Removed [[love.graphics.stencil]] (replaced by [[love.graphics.setStencilMode]]).
+
* Removed support for the GLSL 1.20 and GLSL ES 1.00 [[Shader]] languages. GLSL 3.30 and GLSL ES 3.00 are used by default instead.
* Removed [[love.graphics.setStencilTest]] and [[love.graphics.getStencilTest]] (replaced by [[love.graphics.setStencilMode]] and [[love.graphics.getStencilMode]]).
+
* Removed functions deprecated in LÖVE 11:
 +
** Removed [[love.audio.getSourceCount]] (renamed to [[love.audio.getActiveSourceCount]]).
 +
** Removed [[Source:getChannels]] (renamed to [[Source:getChannelCount]]).
 +
** Removed [[Decoder:getChannels]] (renamed to [[Decoder:getChannelCount]]).
 +
** Removed [[love.filesystem.isDirectory]] (replaced by [[love.filesystem.getInfo]]).
 +
** Removed [[love.filesystem.isFile]] (replaced by [[love.filesystem.getInfo]]).
 +
** Removed [[love.filesystem.isSymlink]] (replaced by [[love.filesystem.getInfo]]).
 +
** Removed [[love.filesystem.getLastModified]] (replaced by [[love.filesystem.getInfo]]).
 +
** Removed [[love.filesystem.getSize]] (replaced by [[love.filesystem.getInfo]]).
 +
** Removed [[ParticleSystem:setAreaSpread]] and [[ParticleSystem:getAreaSpread]] (renamed to [[ParticleSystem:setEmissionArea]] and [[ParticleSystem:getEmissionArea]]).
 +
** Removed [[love.math.compress]] and [[love.math.decompress]] (replaced by [[love.data.compress]] and [[love.data.decompress]]).
 +
** Removed [[World:getBodyList]], [[World:getJointList]], and [[World:getContactList]] (renamed to [[World:getBodies]], [[World:getJoints]], and [[World:getContacts]]).
 +
** Removed [[Body:getFixtureList]], [[Body:getJointList]], and [[Body:getContactList]] (renamed to [[Body:getFixtures]], [[Body:getJoints]], and [[Body:getContacts]]).
 +
** Removed [[PrismaticJoint:hasLimitsEnabled]] (renamed to [[PrismaticJoint:areLimitsEnabled]]).
 +
** Removed [[RevoluteJoint:hasLimitsEnabled]] (renamed to [[RevoluteJoint:areLimitsEnabled]]).
  
  
 
=== Fixes ===
 
=== Fixes ===
 +
* Fixed misleading print when there's an error in the error handler.
 
* Fixed [[BezierCurve:render]] adding collinear points in some situations.
 
* Fixed [[BezierCurve:render]] adding collinear points in some situations.
* Fixed line rendering when the line has duplicate points.
+
* Fixed scissor state getting out of sync when switching between a Canvas and the screen while a [[love.graphics.setScissor|scissor]] is active.
 +
* Fixed a memory leak in [[TextBatch:add]] when the internal buffer is resized.
 +
* Fixed [[AlignMode|justify]] text align mode not always aligning to both edges.
 
* Fixed sound [[Decoder]]s to cause a Lua error instead of hard-crashing when memory for the decoding buffer can't be allocated.
 
* Fixed sound [[Decoder]]s to cause a Lua error instead of hard-crashing when memory for the decoding buffer can't be allocated.
* Fixed oversaturated colors on macOS when a P3-capable display is used.
+
* Fixed full platform-specific paths in [[love.filesystem]] APIs to use a consistent canonical representation for the platform.
  
  
 
[[Category:Versions]]
 
[[Category:Versions]]
 
{{#set:InternalVersion=120}}
 
{{#set:InternalVersion=120}}
{{#set:Codename=TBD}}
+
{{#set:Codename=Bestest Friend}}
 
{{#set:Status=<span style="color:#ff0000;">Not Released</span>}}
 
{{#set:Status=<span style="color:#ff0000;">Not Released</span>}}
 
{{#set:ReleaseDate=TBA}}
 
{{#set:ReleaseDate=TBA}}

Latest revision as of 13:10, 20 January 2025

O.png The information on this page may not be accurate or up to date due to the information pertaining to a version that is currently in development.  


The codename for LÖVE 12.0 is Bestest Friend. It is currently not released.

Changes from 11.5

Additions

General


Data


Filesystem


Audio


Input


Math


Physics


Window


Graphics

  • Added a Metal backend to love.graphics, available on macOS 10.15+ and iOS 13+.
  • Added a Vulkan backend to love.graphics, available on Windows, Linux, and Android 7+.
  • Added '--renderers a,b,c' and '--excluderenderers a,b,c' command line arguments.
  • Added t.graphics.renderers and t.graphics.excluderenderers love.conf options.
  • Added t.graphics.lowpower love.conf option.







Changes

  • Changed the primary build system for Linux to CMake instead of autotools.
  • Changed the minimum runtime macOS version to 10.15.
  • Changed the minimum runtime iOS version to 13.0.
  • Changed the minimum runtime Windows version to Windows 7 SP1 (64 bit).
  • Changed the minimum runtime graphics requirement to OpenGL 3.3+, OpenGL ES 3.0+, Vulkan 1.0+, or Metal.



  • Changed love.filesystem.exists to no longer be deprecated.
  • Changed love.data.hash to have a container type parameter.
  • Changed the size parameter of love.data.newDataView to be optional.
  • Changed the default font from Vera size 12 to Noto Sans size 13.
  • Changed TrueType and OpenType font handling to have improved kerning and character combining support.
  • Changed love.timer.sleep to allow for more precise sleep durations than 1ms on platforms which support that.



  • Changed the Texture class and implementation to no longer have separate Canvas and Image subclasses.
  • Changed Textures created from image files and from ImageData to no longer hold onto a CPU copy of their pixel data after creation.
  • Changed love.graphics.newImage to error instead of loading a placeholder texture, when the image dimensions are too large for the system.
  • Changed love.graphics.newImage to allow creating a mipmapped texture with less than the full mipmap range, instead of erroring.
  • Changed vertex attribute declarations in Shader code to use location indices via the layout (location = #) qualifier, instead of using names to match with Mesh vertex attributes.
    • LÖVE's default vertex attributes use location 0 for position, location 1 for texture coordinates, and location 2 for vertex colors.
  • Changed the vertex format used with love.graphics.newMesh to have format and 'location' named fields.
  • Changed love.graphics.newMesh to no longer default to the "fan" Mesh draw mode.
  • Changed the behaviour of Meshes to no longer allow a vertex map or index buffer when the "fan" mesh draw mode is used.
  • Changed love.graphics.draw(Mesh) to no longer error if the Mesh has no 'VertexPosition' attribute but does have custom vertex attributes.
  • Changed Mesh:getVertexFormat to use named fields, to match the new vertex format parameter setup in love.graphics.newMesh.
  • Changed love.window.setMode to no longer clear the contents of Canvases or otherwise recreate graphics resources.
  • Changed love.graphics.rectangle, love.graphics.polygon, and other shape drawing APIs to provide texture coordinates to shaders, for filled shapes.
  • Changed love.graphics.points to require 'love_PointSize' to be set in the vertex shader, if a custom shader is used.
  • Changed love.graphics.setCanvas to always clear auto-generated temporary depth and stencil buffers when they're used.
  • Changed love.graphics.clear to no longer be affected by love.graphics.setScissor or love.graphics.setColorMask.
  • Changed love.graphics.setDepthMode with the depth write parameter set to true to error if the active Canvases or window don't have a depth buffer.
  • Changed text layout and rendering in high-dpi situations to be more consistent across DPI scales.
  • Changed Shader code parsing to ignore shader entry point functions inside comments.
  • Changed Shader code to use GLSL3 (GLSL 3.30 or GLSL ES 3.00) by default.
  • Changed position output coordinate space in vertex shaders to be consistent across all graphics APIs and regardless of whether a Canvas is active.
    • Clip-space output is y-up. Texture contents and pixel shader coordinates are y-down.


  • Changed audio file decoding to choose the most appropriate decoder based on file contents instead of the file extension.
  • Changed audio initialization to give a more descriptive error if it fails.
  • Changed Videos to stream audio from the file instead of loading all the video file into memory for use with audio decoding.
  • Changed love.math.perlinNoise and love.math.simplexNoise to use higher precision numbers for its internal calculations.
  • Changed the window 'depth' field in love.conf and love.window.setMode/updateMode/getMode to be a boolean instead of a bit count number.
  • Changed love.window.isVisible to return false if the window is minimized.
  • Changed love.visible to be called when minimizing and unminimizing the window.



  • Updated SDL from 2.0 to 3.0.
  • Updated Box2D from 2.3 to 2.4.1


Deprecations


Removals


Fixes

  • Fixed misleading print when there's an error in the error handler.
  • Fixed BezierCurve:render adding collinear points in some situations.
  • Fixed scissor state getting out of sync when switching between a Canvas and the screen while a scissor is active.
  • Fixed a memory leak in TextBatch:add when the internal buffer is resized.
  • Fixed justify text align mode not always aligning to both edges.
  • Fixed sound Decoders to cause a Lua error instead of hard-crashing when memory for the decoding buffer can't be allocated.
  • Fixed full platform-specific paths in love.filesystem APIs to use a consistent canonical representation for the platform.