You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-11 13:10:58 +00:00
Refactored Mesh internals and formats.
-Changed how mesh data is organized, hoping to make it more efficient on Vulkan and GLES. -Removed compression, it now always uses the most efficient format. -Added support for custom arrays (up to 8 custom formats) -Added support for 8 weights in skeleton data. -Added a simple optional versioning system for imported assets, to reimport if binary is newer -Fixes #43979 (I needed to test) WARNING: -NOT backwards compatible with previous 4.x-devel, will most likely never be, but it will force reimport scenes due to version change. -NOT backwards compatible with 3.x scenes, this will be eventually re-added. -Skeletons not working any longer, will fix in next PR.
This commit is contained in:
@@ -615,6 +615,7 @@ int RenderingDeviceVulkan::get_format_vertex_size(DataFormat p_format) {
|
||||
case DATA_FORMAT_B8G8R8A8_SNORM:
|
||||
case DATA_FORMAT_B8G8R8A8_UINT:
|
||||
case DATA_FORMAT_B8G8R8A8_SINT:
|
||||
case DATA_FORMAT_A2B10G10R10_UNORM_PACK32:
|
||||
return 4;
|
||||
case DATA_FORMAT_R16_UNORM:
|
||||
case DATA_FORMAT_R16_SNORM:
|
||||
@@ -3528,7 +3529,7 @@ RenderingDevice::VertexFormatID RenderingDeviceVulkan::vertex_format_create(cons
|
||||
ERR_FAIL_COND_V(used_locations.has(p_vertex_formats[i].location), INVALID_ID);
|
||||
|
||||
ERR_FAIL_COND_V_MSG(get_format_vertex_size(p_vertex_formats[i].format) == 0, INVALID_ID,
|
||||
"Data format for attachment (" + itos(i) + ") is not valid for a vertex array.");
|
||||
"Data format for attachment (" + itos(i) + "), '" + named_formats[p_vertex_formats[i].format] + "', is not valid for a vertex array.");
|
||||
|
||||
vdcache.bindings[i].binding = i;
|
||||
vdcache.bindings[i].stride = p_vertex_formats[i].stride;
|
||||
|
||||
Reference in New Issue
Block a user