This is the design task for supporting tiled images (and therefore UDIM textures) in Blender.
== Basics ==
Essentially, a tiled image consists of multiple files, where each file covers one unit square in the UV space.
Currently, the layout is hardcoded to ten tiles per row which is the standard for UDIM textures.
UDIM refers to a naming scheme for these tiles - tile (x, y) is assigned the number 1001 + 10*y + x. Most of Blender doesn't need to care about this, it's only really relevant for loading/saving files and displaying them in the UI.
== Implementation ==
Fundamentally, tiled textures are similar to image sequences - they consist of a number of image files and buffers. Therefore, the core implementation is handled like image sequences which allows to reuse the existing image cache. This is done by adding a new source type, `IMA_SRC_TILED`, which specifies that the image consists of multiple tiles.
The ImageUser now contains a tile index that is used when acquiring the ImBuf, and the Image contains the number of tiles.
== Tasks ==
Generally, the remaining work is to update all the areas that access images in Blender and handle the tiles correctly. These areas can be roughly split into "using images" and "editing images" - for example, support in the Viewport, Eevee and Cycles are essential for using tiles textures, while support in texture painting and baking is only needed for editing and/or creating them.
Since the main motivation for UDIM support is the ability to use textures generated with external tools, the "using images" part has priority.
== ToDos ==
===== Basics =====
- ~~Support in the core~~ (rB9220f3b64f97)
- ~~Detecting UDIMs automatically when opening them~~ (rBa5732a1de482)
- Adding or removing tiles
- Creating tiled images from Blender
- Saving tiled images
- Packing/Unpacking tiled images
===== Image Editor =====
- ~~Showing all tiles in the Image Editor~~ (rB89c0dc4ebdb8)
- ~~Supporting Image Editor operators like color sampling~~ (rB5c62468e4b39)
- Labeling/Naming tiles
- Optionally showing a tile grid even without a loaded image for laying out UVs
- ~~Texture painting support~~ (rBcc4defac041f)
===== 3D texture painting =====
- Support for drawing on tiled images
- Maybe support drawing across tile borders
===== Cycles =====
- ~~Support tiled images as Cycles textures in SVM mode~~ (rB62550b490ac6)
- Support tiled images as Cycles textures in OSL mode
- Support baking to tiled images
===== Eevee =====
- ~~Support tiled images as textures~~ (rB94d0cbf12782)
===== More coming =====