android - 3d 模型的背景图像可渲染
问题描述
在我的应用程序中,我需要为添加到场景视图的 3d modelRenderable 对象开发全屏背景图像。
我按照主题中描述的方式做到了:https ://github.com/google-ar/sceneform-android-sdk/issues/332
从 imageView 资源创建 ViewRenderable 对象并将其添加到包含我的 3d modelRenderable 的场景视图中。使用 setLocalPosition(0,0,-2) 作为带有图像的锚节点,因此它显示为 3d 模型的背景,但图像的大小发生了变化,现在不是全屏。我尝试使用带有硬编码值的 setLocalScale/setWorldScale。
这仅解决了特定设备的问题(如果我在不同的设备上运行应用程序 - 图像将不是全屏)。寻找适用于所有设备的解决方案。
解决方案
推荐阅读
- regex - 如何设置单元格中的最大字符数并在 Google 表格中达到最大字符数时自动跳过 2 行?
- c# - Microsoft 媒体编码器屏幕截图,保存正在录制的视频的特定部分
- git - 是否可以将 git repo 标记作为变量传递给 ADO 构建管道?
- javascript - AngularJS返回主页的问题
- javascript - Youtube 剪辑自动播放并在按下时从头开始
- amazon-web-services - 为什么我收到 ClusterNotFoundException The referenced cluster is inactive?
- c# - 阻止特定 c# winforms 的桌面共享或检测桌面共享
- python - 如何检查作者是否在 x 服务器中具有 x 角色?
- ios - UITapGestureRecognizer 在导航栏 titleView 中的 UIView 上不起作用?
- webpack - AddSpaStaticFiles 'RootPath' 默默地破坏了 webpack devServer 的 HMR