How to make a transparent background?

YeHuangYeHuang AUMember ✭✭

I want to display a 3D model on Xamarin form, however, after I use "viewPort.SetClearColor(Color.Transparent);", the background is become black without become transparent.

So how to make background become transparent? So I can display the Xamarin view background under the 3D model.

Thanks

Answers

  • RayKoopaRayKoopa DEMember ✭✭

    I doubt that's going to happen to you unless someone can show us a trick of keying a transparent color of the Urho control, and so far I haven't seen anything like that.

    The problem is that the clear color ignores the alpha component of whatever color you pass in, so Transparent effectively becomes Black; it's not possible otherwise, as the backbuffer always requires a solid color AFAIK.

    You could try cheating by giving your app and the clear color the same solid color so nobody would notice. Or place the 3D model on a card-like element with the same background color.

Sign In or Register to comment.