Skip to content

[RFC] Wrap existing library #197

@kvark

Description

@kvark

This is a crazy idea that is quite far from the rough reality, but we can at least discuss/consider it here.
Spawned by discussion in #159:

The more I look at it, the more I become obsessed with an idea that euclid could just be a shim around cgmath with a few typedefs (and maybe Size?) defined. That would reduce the library fragmentation and benefit the community.

The major thing missing from cgmath is typed spaces - the U generic parameter. I suggest having a wrapper defined like type Wrap<V, U> = (V, PhantomType<U>) and defining all our unit-related operations on it, but also having it to inherit all the operations of V, just used on the same Wrap<V, U> type. This is roughly the idea to explore.

cc @nical @nox

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions