- ControlRenderer controlRenderer = factory.CreateControlRenderer( propertyMap );
- DALI_TEST_CHECK( controlRenderer );
-
- //Add renderer to an actor on stage.
- Actor actor = Actor::New();
- actor.SetSize( 200.f, 200.f );
- Stage::GetCurrent().Add( actor );
- controlRenderer.SetSize( Vector2( 200.f, 200.f ) );
- controlRenderer.SetOnStage( actor );
-
- DALI_TEST_CHECK( actor.GetRendererCount() == 1u );
-
- //Attempt to render to queue resource load requests.
- application.SendNotification();
- application.Render( 0 );
-
- //Tell the platform abstraction that the required resources have been loaded.
- TestPlatformAbstraction& platform = application.GetPlatform();
- platform.SetAllResourceRequestsAsLoaded();
-
- //Render again to upload the now-loaded textures.
- application.SendNotification();
- application.Render( 0 );
-
- TestGlAbstraction& gl = application.GetGlAbstraction();
-
- //Test to see if the object has not been loaded, as expected.
- Matrix scaleMatrix;
- DALI_TEST_CHECK( ! gl.GetUniformValue<Matrix>( "uObjectMatrix", scaleMatrix ) );
-
- controlRenderer.SetOffStage( actor );
- DALI_TEST_CHECK( actor.GetRendererCount() == 0u );