|
|
|
@ -43,133 +43,132 @@ |
|
|
|
|
|
|
|
|
|
|
|
namespace Magnum { namespace Trade { namespace Test { namespace { |
|
|
|
namespace Magnum { namespace Trade { namespace Test { namespace { |
|
|
|
|
|
|
|
|
|
|
|
class MaterialDataTest: public TestSuite::Tester { |
|
|
|
struct MaterialDataTest: TestSuite::Tester { |
|
|
|
public: |
|
|
|
explicit MaterialDataTest(); |
|
|
|
explicit MaterialDataTest(); |
|
|
|
|
|
|
|
|
|
|
|
void textureSwizzleComponentCount(); |
|
|
|
void textureSwizzleComponentCount(); |
|
|
|
void attributeTypeSize(); |
|
|
|
void attributeTypeSize(); |
|
|
|
void attributeTypeSizeInvalid(); |
|
|
|
void attributeTypeSizeInvalid(); |
|
|
|
|
|
|
|
|
|
|
|
void attributeMap(); |
|
|
|
void attributeMap(); |
|
|
|
void layerMap(); |
|
|
|
void layerMap(); |
|
|
|
|
|
|
|
|
|
|
|
void constructAttributeDefault(); |
|
|
|
void constructAttributeDefault(); |
|
|
|
void constructAttributeString(); |
|
|
|
void constructAttributeString(); |
|
|
|
void constructAttributeName(); |
|
|
|
void constructAttributeName(); |
|
|
|
void constructAttributeTypeErasedString(); |
|
|
|
void constructAttributeTypeErasedString(); |
|
|
|
void constructAttributeTypeErasedName(); |
|
|
|
void constructAttributeTypeErasedName(); |
|
|
|
|
|
|
|
|
|
|
|
template<class T> void constructAttributeStringConstexpr(); |
|
|
|
template<class T> void constructAttributeStringConstexpr(); |
|
|
|
|
|
|
|
|
|
|
|
void constructAttributePointer(); |
|
|
|
void constructAttributePointer(); |
|
|
|
void constructAttributeMutablePointer(); |
|
|
|
void constructAttributeMutablePointer(); |
|
|
|
void constructAttributeStringNameStringValue(); |
|
|
|
void constructAttributeStringNameStringValue(); |
|
|
|
void constructAttributeNameStringValue(); |
|
|
|
void constructAttributeNameStringValue(); |
|
|
|
void constructAttributeTextureSwizzle(); |
|
|
|
void constructAttributeTextureSwizzle(); |
|
|
|
void constructAttributeLayer(); |
|
|
|
void constructAttributeLayer(); |
|
|
|
|
|
|
|
|
|
|
|
void constructAttributeInvalidName(); |
|
|
|
void constructAttributeInvalidName(); |
|
|
|
void constructAttributeInvalidLayerName(); |
|
|
|
void constructAttributeInvalidLayerName(); |
|
|
|
void constructAttributeWrongTypeForName(); |
|
|
|
void constructAttributeWrongTypeForName(); |
|
|
|
void constructAttributeInvalidType(); |
|
|
|
void constructAttributeInvalidType(); |
|
|
|
void constructAttributeEmptyName(); |
|
|
|
void constructAttributeEmptyName(); |
|
|
|
void constructAttributeEmptyNameString(); |
|
|
|
void constructAttributeEmptyNameString(); |
|
|
|
void constructAttributeTooLarge(); |
|
|
|
void constructAttributeTooLarge(); |
|
|
|
void constructAttributeTooLargeString(); |
|
|
|
void constructAttributeTooLargeString(); |
|
|
|
void constructAttributeTooLargeNameString(); |
|
|
|
void constructAttributeTooLargeNameString(); |
|
|
|
void constructAttributeWrongAccessType(); |
|
|
|
void constructAttributeWrongAccessType(); |
|
|
|
void constructAttributeWrongAccessPointerType(); |
|
|
|
void constructAttributeWrongAccessPointerType(); |
|
|
|
void constructAttributeWrongAccessTypeString(); |
|
|
|
void constructAttributeWrongAccessTypeString(); |
|
|
|
|
|
|
|
|
|
|
|
void construct(); |
|
|
|
void construct(); |
|
|
|
void constructEmptyAttribute(); |
|
|
|
void constructEmptyAttribute(); |
|
|
|
void constructDuplicateAttribute(); |
|
|
|
void constructDuplicateAttribute(); |
|
|
|
void constructFromImmutableSortedArray(); |
|
|
|
void constructFromImmutableSortedArray(); |
|
|
|
|
|
|
|
|
|
|
|
void constructLayers(); |
|
|
|
void constructLayers(); |
|
|
|
void constructLayersNotMonotonic(); |
|
|
|
void constructLayersNotMonotonic(); |
|
|
|
void constructLayersOffsetOutOfBounds(); |
|
|
|
void constructLayersOffsetOutOfBounds(); |
|
|
|
|
|
|
|
|
|
|
|
void constructNonOwned(); |
|
|
|
void constructNonOwned(); |
|
|
|
void constructNonOwnedLayers(); |
|
|
|
void constructNonOwnedLayers(); |
|
|
|
void constructNonOwnedEmptyAttribute(); |
|
|
|
void constructNonOwnedEmptyAttribute(); |
|
|
|
void constructNonOwnedNotSorted(); |
|
|
|
void constructNonOwnedNotSorted(); |
|
|
|
void constructNonOwnedDuplicateAttribute(); |
|
|
|
void constructNonOwnedDuplicateAttribute(); |
|
|
|
void constructNonOwnedLayersNotMonotonic(); |
|
|
|
void constructNonOwnedLayersNotMonotonic(); |
|
|
|
void constructNonOwnedLayersOffsetOutOfBounds(); |
|
|
|
void constructNonOwnedLayersOffsetOutOfBounds(); |
|
|
|
void constructNonOwnedAttributeFlagOwned(); |
|
|
|
void constructNonOwnedAttributeFlagOwned(); |
|
|
|
void constructNonOwnedLayerFlagOwned(); |
|
|
|
void constructNonOwnedLayerFlagOwned(); |
|
|
|
|
|
|
|
|
|
|
|
void constructCopy(); |
|
|
|
void constructCopy(); |
|
|
|
void constructMove(); |
|
|
|
void constructMove(); |
|
|
|
|
|
|
|
|
|
|
|
void as(); |
|
|
|
void as(); |
|
|
|
void asRvalue(); |
|
|
|
void asRvalue(); |
|
|
|
|
|
|
|
|
|
|
|
void access(); |
|
|
|
void access(); |
|
|
|
void accessPointer(); |
|
|
|
void accessPointer(); |
|
|
|
void accessString(); |
|
|
|
void accessString(); |
|
|
|
void accessTextureSwizzle(); |
|
|
|
void accessTextureSwizzle(); |
|
|
|
void accessMutable(); |
|
|
|
void accessMutable(); |
|
|
|
void accessOptional(); |
|
|
|
void accessOptional(); |
|
|
|
void accessOutOfBounds(); |
|
|
|
void accessOutOfBounds(); |
|
|
|
void accessNotFound(); |
|
|
|
void accessNotFound(); |
|
|
|
void accessInvalidAttributeName(); |
|
|
|
void accessInvalidAttributeName(); |
|
|
|
void accessWrongType(); |
|
|
|
void accessWrongType(); |
|
|
|
void accessWrongPointerType(); |
|
|
|
void accessWrongPointerType(); |
|
|
|
void accessWrongTypeString(); |
|
|
|
void accessWrongTypeString(); |
|
|
|
|
|
|
|
|
|
|
|
void accessLayers(); |
|
|
|
void accessLayers(); |
|
|
|
void accessLayersDefaults(); |
|
|
|
void accessLayersDefaults(); |
|
|
|
void accessLayersTextured(); |
|
|
|
void accessLayersTextured(); |
|
|
|
void accessLayersTexturedDefault(); |
|
|
|
void accessLayersTexturedDefault(); |
|
|
|
void accessLayersTexturedSingleMatrixCoordinatesLayer(); |
|
|
|
void accessLayersTexturedSingleMatrixCoordinatesLayer(); |
|
|
|
void accessLayersTexturedBaseMaterialMatrixCoordinatesLayer(); |
|
|
|
void accessLayersTexturedBaseMaterialMatrixCoordinatesLayer(); |
|
|
|
void accessLayersInvalidTextures(); |
|
|
|
void accessLayersInvalidTextures(); |
|
|
|
|
|
|
|
|
|
|
|
void accessLayerLayerNameInBaseMaterial(); |
|
|
|
void accessLayerLayerNameInBaseMaterial(); |
|
|
|
void accessLayerEmptyLayer(); |
|
|
|
void accessLayerEmptyLayer(); |
|
|
|
void accessLayerIndexMutable(); |
|
|
|
void accessLayerIndexMutable(); |
|
|
|
void accessLayerNameMutable(); |
|
|
|
void accessLayerNameMutable(); |
|
|
|
void accessLayerStringMutable(); |
|
|
|
void accessLayerStringMutable(); |
|
|
|
void accessLayerIndexOptional(); |
|
|
|
void accessLayerIndexOptional(); |
|
|
|
void accessLayerNameOptional(); |
|
|
|
void accessLayerNameOptional(); |
|
|
|
void accessLayerStringOptional(); |
|
|
|
void accessLayerStringOptional(); |
|
|
|
void accessLayerOutOfBounds(); |
|
|
|
void accessLayerOutOfBounds(); |
|
|
|
void accessLayerNotFound(); |
|
|
|
void accessLayerNotFound(); |
|
|
|
void accessInvalidLayerName(); |
|
|
|
void accessInvalidLayerName(); |
|
|
|
void accessOutOfBoundsInLayerIndex(); |
|
|
|
void accessOutOfBoundsInLayerIndex(); |
|
|
|
void accessOutOfBoundsInLayerString(); |
|
|
|
void accessOutOfBoundsInLayerString(); |
|
|
|
void accessNotFoundInLayerIndex(); |
|
|
|
void accessNotFoundInLayerIndex(); |
|
|
|
void accessNotFoundInLayerString(); |
|
|
|
void accessNotFoundInLayerString(); |
|
|
|
void accessMutableNotAllowed(); |
|
|
|
void accessMutableNotAllowed(); |
|
|
|
|
|
|
|
|
|
|
|
void releaseAttributes(); |
|
|
|
void releaseAttributes(); |
|
|
|
void releaseLayers(); |
|
|
|
void releaseLayers(); |
|
|
|
|
|
|
|
|
|
|
|
void templateLayerAccess(); |
|
|
|
void templateLayerAccess(); |
|
|
|
void templateLayerAccessMutable(); |
|
|
|
void templateLayerAccessMutable(); |
|
|
|
|
|
|
|
|
|
|
|
void debugLayer(); |
|
|
|
void debugLayer(); |
|
|
|
/* No packed version, as layer name is stored as a string */ |
|
|
|
/* No packed version, as layer name is stored as a string */ |
|
|
|
void debugAttribute(); |
|
|
|
void debugAttribute(); |
|
|
|
/* No packed version, as attribute name is stored as a string */ |
|
|
|
/* No packed version, as attribute name is stored as a string */ |
|
|
|
void debugTextureSwizzle(); |
|
|
|
void debugTextureSwizzle(); |
|
|
|
void debugTextureSwizzlePacked(); |
|
|
|
void debugTextureSwizzlePacked(); |
|
|
|
void debugAttributeType(); |
|
|
|
void debugAttributeType(); |
|
|
|
void debugAttributeTypePacked(); |
|
|
|
void debugAttributeTypePacked(); |
|
|
|
|
|
|
|
|
|
|
|
void debugType(); |
|
|
|
void debugType(); |
|
|
|
void debugTypePacked(); |
|
|
|
void debugTypePacked(); |
|
|
|
void debugTypes(); |
|
|
|
void debugTypes(); |
|
|
|
void debugTypesPacked(); |
|
|
|
void debugTypesPacked(); |
|
|
|
#ifdef MAGNUM_BUILD_DEPRECATED |
|
|
|
#ifdef MAGNUM_BUILD_DEPRECATED |
|
|
|
void debugFlag(); |
|
|
|
void debugFlag(); |
|
|
|
void debugFlags(); |
|
|
|
void debugFlags(); |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
void debugAlphaMode(); |
|
|
|
void debugAlphaMode(); |
|
|
|
void debugAlphaModePacked(); |
|
|
|
void debugAlphaModePacked(); |
|
|
|
|
|
|
|
}; |
|
|
|
}; |
|
|
|
|
|
|
|
|
|
|
|
MaterialDataTest::MaterialDataTest() { |
|
|
|
MaterialDataTest::MaterialDataTest() { |
|
|
|
|