Thank you very much!
Got it working on iOS by following this steps and adding the next code
- (void)preStartUnity {
self.window.backgroundColor = [[UIColor clearColor] colorWithAlphaComponent:0];
}
2020.1.9f1
i made the background transparent but i want to make it so that you can control your phone while the app is open
but only where there are no ui elements such as, the app is open, the background is transparent and i was on the home screen opening the appā¦ now i want to swipe to go to a different page of the home screen.
How can i Do This?
You canāt do that, afaik.
okā¦
Hi, is it possible to achieve this with Unity 2019.4.31f1, cannot find the āPreserve frame buffer alphaā option.
Thanks
Doesnāt work in 2022.1.8.f1
Exported as android project, made fixes in manifests and styles.xml but it doesnāt help
Hi do you guys know how i could filter touches? Like if the user clicks on a button it registers it and if he or she clicks on the transparent parts, then the interaction is on the app on the background?
I managed to render the unity frame inside a react native application with transparent background, despite htat this take me to ābrokeā the application because of AndroidManifest merge conflict during building. The conflict happen for the android:theme attribute: the base AppTheme and the Unity.Translucent canāt coexist in . So i replace the AppTheme with Translucent in AndroidManifest and everything works except for the app boot where it appears transparent before loading the view.
This is the merged manifest after replace. blue section is UnityManifest and red seciont is React Native manifest.
I did this and it works, but is there a way to apply post processing effects over the Native UI to saturate or desaturate it. If no, can I achieve that any way, custom shaders? Anything? I want post effects to work for the Android screen. Pls help
Can you do the same (transparent background) on an iOS app?
I included a Unity3D game into my native Android app inside of a FrameLayout. I am trying to get the background of the Unity content transparent such that only the 3D Object is visible. Iāve already tried the following:
In my Unity Project
I set the Camera āClear Flagā to āSolid Colorā and chose #000000 as the color (0 alpha).
In the āPlayer Settingsā Iāve checked the option Render over native UI.
Opened the exported Unity project in my Android studio
besides the necessary configs for the library part I tried out various things to get the transparent behaviour working. Iāve tried creating custom styles setting translucient and transparent color and assigned it to the Activity in the AndroidManifest. Iāve tried to set the Z order of the view in the OnCreate Method. Iāve try to set the background color of the mUnityPlayer manually in the OnCreate method. But all that didnāt work. The Unity content inside of my native android app always renders with the color Iāve selected without setting the alpha value to 0.
I would be more than thankful if anyoune could provide some help on this.
Hi,Iām using 2021.3.21f1.
refer to https://issuetracker.unity3d.com/issues/android-crash-when-using-unityplayer-getapplicationcontext-this-on-exported-andoid-projects
the background is transparent when I using ānew UnityPlayer(this, this).ā
but Itās not work when I using āUnityPlayer(getApplicationContext(), this);ā
how to solve this problem?
Hi, Can you share you demo project?
Hello, has anyone succeeded in including their Unity project in a native Android application with a transparent background? I have tried all the tips on Unity 2022.3.35, and nothing works. Thank you in advance for your help.