added uniform interface for primitives