DALI_TEST_CHECK(renderer);
TextureSet textureSet = renderer.GetTextures();
- DALI_TEST_EQUALS(textureSet.GetTextureCount(), 7u, TEST_LOCATION);
+ DALI_TEST_EQUALS(textureSet.GetTextureCount(), 9u, TEST_LOCATION);
- Texture diffuseTexture = textureSet.GetTexture(5u);
- Texture specularTexture = textureSet.GetTexture(6u);
+ Texture diffuseTexture = textureSet.GetTexture(7u);
+ Texture specularTexture = textureSet.GetTexture(8u);
model.SetImageBasedLightSource(TEST_DIFFUSE_TEXTURE, TEST_SPECULAR_TEXTURE);
- Texture newDiffuseTexture = textureSet.GetTexture(5u);
- Texture newSpecularTexture = textureSet.GetTexture(6u);
+ Texture newDiffuseTexture = textureSet.GetTexture(7u);
+ Texture newSpecularTexture = textureSet.GetTexture(8u);
DALI_TEST_NOT_EQUALS(diffuseTexture, newDiffuseTexture, 0.0f, TEST_LOCATION);
DALI_TEST_NOT_EQUALS(specularTexture, newSpecularTexture, 0.0f, TEST_LOCATION);
DALI_TEST_CHECK(renderer);
TextureSet textureSet = renderer.GetTextures();
- DALI_TEST_EQUALS(textureSet.GetTextureCount(), 7u, TEST_LOCATION);
+ DALI_TEST_EQUALS(textureSet.GetTextureCount(), 9u, TEST_LOCATION);
- Texture diffuseTexture = textureSet.GetTexture(5u);
- Texture specularTexture = textureSet.GetTexture(6u);
+ Texture diffuseTexture = textureSet.GetTexture(7u);
+ Texture specularTexture = textureSet.GetTexture(8u);
model.SetImageBasedLightSource("", "");
- Texture newDiffuseTexture = textureSet.GetTexture(5u);
- Texture newSpecularTexture = textureSet.GetTexture(6u);
+ Texture newDiffuseTexture = textureSet.GetTexture(7u);
+ Texture newSpecularTexture = textureSet.GetTexture(8u);
DALI_TEST_EQUALS(diffuseTexture, newDiffuseTexture, TEST_LOCATION);
DALI_TEST_EQUALS(specularTexture, newSpecularTexture, TEST_LOCATION);
DALI_TEST_CHECK(renderer);
TextureSet textureSet = renderer.GetTextures();
- DALI_TEST_EQUALS(textureSet.GetTextureCount(), 7u, TEST_LOCATION);
+ DALI_TEST_EQUALS(textureSet.GetTextureCount(), 9u, TEST_LOCATION);
- Texture diffuseTexture = textureSet.GetTexture(5u);
- Texture specularTexture = textureSet.GetTexture(6u);
+ Texture diffuseTexture = textureSet.GetTexture(7u);
+ Texture specularTexture = textureSet.GetTexture(8u);
model.SetImageBasedLightSource("dummy.ktx", "dummy.ktx");
- Texture newDiffuseTexture = textureSet.GetTexture(5u);
- Texture newSpecularTexture = textureSet.GetTexture(6u);
+ Texture newDiffuseTexture = textureSet.GetTexture(7u);
+ Texture newSpecularTexture = textureSet.GetTexture(8u);
DALI_TEST_EQUALS(diffuseTexture, newDiffuseTexture, TEST_LOCATION);
DALI_TEST_EQUALS(specularTexture, newSpecularTexture, TEST_LOCATION);
END_TEST;
}
+int UtcDaliModelColorMode(void)
+{
+ ToolkitTestApplication application;
+
+ Scene3D::Model model = Scene3D::Model::New(TEST_GLTF_FILE_NAME);
+ model.SetProperty(Dali::Actor::Property::SIZE, Vector2(50, 50));
+ model.SetProperty(Dali::Actor::Property::COLOR, Color::RED);
+
+ application.GetScene().Add(model);
+
+ application.SendNotification();
+ application.Render();
+
+ Actor actor = model.FindChildByName("AnimatedCube");
+ Vector4 childColor = actor[Dali::Actor::Property::COLOR];
+ Vector4 childWorldColor = actor[Dali::Actor::Property::WORLD_COLOR];
+
+ DALI_TEST_EQUALS(childColor, Color::WHITE, TEST_LOCATION);
+ DALI_TEST_EQUALS(childWorldColor, Color::RED, TEST_LOCATION);
+
+ END_TEST;
+}
+
// For ResourceReady
namespace
{