Skip to content

Allow Adding already-packed Rectangles to be added as-is to a packer #2

@Raildex

Description

@Raildex

Scenario:
I want to pack polygon Texture Coordinates.

For that I go through each polygon and return the packed rectangle's absolute pixel rectangle coordinates back to the polygon and are later transformed to UV coordinates by dividing by the dimensions of the resulting bounds later.

However, since I do not know how many rectangles I am about to pack, I can't have a "upper limit" for the bounds. For this reason, I would welcome a method to add a List<PackedRectangle> to an already existing Packer which just adds the Packed Rectangles to the packer's internal list. (if the rectangles do not fit because the bounds are too small, just throw an exception?)

This way, The Bounds can grow without invalidating previous packed rectangles.

image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions