Google统一纸板在Android设备上禁用了AA [英] Google cardboard for unity disables AA on android device

查看:101
本文介绍了Google统一纸板在Android设备上禁用了AA的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用Google纸板SDK统一为Android开发简单的VR应用.我正在使用unity 5(免费)和最新版本的纸板包装,以实现unity(0.4.9),我正在对Sony xperia z3 compact(lolipop)和三星银河笔记3(kitkat)进行测试

I'm developing simple VR app for android using google cardboard SDK for unity. I'm using unity 5(free), and latest version cardboard package for unity(0.4.9), i am testing on sony xperia z3 compact(lolipop) and on samsung galaxy note 3(kitkat)

我遇到的问题是,我无法打开抗锯齿功能,或者说是Google sdk软件包,似乎禁用了它.我不介意有一些锯齿状的拐角,但事实是,当这些拐角距离足够远时,这些拐角就会闪烁.我尝试将纹理分开(因为闪烁可能是重叠导致的),但问题仍然存在.

The issue i'm having is, that i can't turn on anti-aliasing, or rather google sdk package, seems to disable it. I dont mind a little jagged corners, but the thing is that those corners are flickering when they are far away enough. I tried moving textures apart(since the flickering could be result of overlapping), but issue still persists.

对于Android来说,统一导出不是问题,因为如果我使用由Unity提供的,由Cardboard主要gameobject插入的库存摄像机构建相同的项目(在Google纸板unity包中提供了测试示例),则AA正在运行.一旦立方体和一台摄像机,它就不会比这更简单...我尝试在播放器设置中打开和关闭32位显示缓冲区选项,尝试强制打开GL ES 2.0并在统一提示中找到其他打勾/取消勾打复选框跨网络,但没有成功.

It can't be the issue with the unity exporting for android, since if i build same project(test example provided inside google cardboard unity package) using stock camera provided by unity, insted of Cardboard main gameobject), AA is working. It cant get simpler than that, once cube and one camera... I have tried turning on and off the 32-bit display buffer option in player settings, tried forcing open GL ES 2.0 and various other tick/untick checkbox inside unity tips found across web, with no success.

所以我的问题是,还有其他人遇到过同样的问题吗?以及如何解决?

So my question is, is anyone else having this same issue. And how to fix it?

我希望我的问题和问题描述足够详细.

I hope my question and description of the problem are detailed enough.

欢呼

推荐答案

Cardboard.cs类包含一个RenderTexture,这是相机渲染的内容,然后通过对镜头进行畸变校正将其重新渲染到手机屏幕上.这样会绕过Unity正常显示到屏幕的情况,因此该项目的AA设置不会有任何效果.

The Cardboard.cs class holds a RenderTexture which is what the cameras render to, and then it is rerendered to the phone screen with distortion correction for the lenses. This bypasses Unity's normal rendering to the screen, so the AA settings for the project won't have any effect.

要查看Unity中的AA设置会有什么效果,您可以做几件事:

To see what effect AA settings in Unity will have, you can do a couple of different things:

  1. 关闭Cardboard.SDK.nativeDistortionCorrection,以使Unity直接绘制到屏幕上,或者
  2. 编辑Cardboard.CreateStereoScreen()并更改在此分配的RenderTexture上的设置.

但是,用于失真的本机代码重新渲染未在帧缓冲区中使用抗锯齿功能,因此我不确定在#2中会看到多少效果.当然,这两种方法都会对性能造成不利影响.

However, the native code rerender for distortion does not use anti-aliasing in the framebuffer, so I'm not sure how much effect you'll see in #2. And there will certainly be a performance penalty either way.

这篇关于Google统一纸板在Android设备上禁用了AA的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆