这是indexloc提供的服务,不要输入任何密码
Skip to content

"Multisampled" textures with sampleCount=1? #1226

@kainino0x

Description

@kainino0x

A long, long time ago we decided that all textures would be conceptually "multisample" and some usages would simply require sampleCount=1. This seems to be what Vulkan has done. However, Metal doesn't make this decision and has MTLTextureType2D and MTLTextureType2DMultisample.

This becomes a problem with argument buffers because they also distinguish the two types. I haven't looked at argument buffers closely but @kvark says you can't just take a 2d texture and put it in a 2d-multisample argument buffer slot.

In particular, in bind group layouts, this means you can't bind a texture with sampleCount=1 to a "multisampled-texture" binding point. This really seems like something that should be possible. But with the constraints of Metal (and possibly D3D12?), it seems necessary for texture creation to distinguish non-multisample textures from single-sampled-multisample textures.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions