android - 谷歌眼镜 : imageView fullscreen?

标签 android imageview google-glass google-gdk

使用 Google Glass,我想知道是否可以拥有一个占用所有空间的 imageView?

使用下面的代码,我在图像周围总是有 10px 的东西:

<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/relativelayoutImage"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:padding="0sp"
android:layout_margin="0sp" >

<ImageView
    android:id="@+id/myImageView"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:keepScreenOn="true"
    android:scaleType="fitXY"
    android:src="@drawable/splashscreen" />

</LinearLayout>

最佳答案

如果您确定没有内边距或主题,您的 View 可能已经是全屏了。那个神秘的额外空间不是玻璃屏幕的一部分或不可用。

试试这个:

adb shell screencap -p /sdcard/screen.png
adb pull /sdcard/screen.png

您会看到来自帧缓冲区的图像周围没有 10 像素。

我不确定你的情况,但这就是发生在我身上的事情。

enter image description here

关于android - 谷歌眼镜 : imageView fullscreen?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/25605961/

相关文章:

android - ImageFactory.imageAsResized 返回 null

android - Android 浏览器中书签的文件夹层次结构

android - Google+ 登录 : Google Play Services out of date exception

android - 使用 Wifi Direct 发现对等点的替代方法,因为它需要两部手机都运行 WiFi Direct 发现

google-glass - 我如何在 Google APIs 控制台看到 Google Mirror API

google-glass - Google Glass GDK - 在导航意图中指定模式

java - Google glass 返回 glass.widget.CardBuilder 的 NoClassDefFoundError

android - 如何在 android 中将动态字符串设置为 Edittext 字段的 Id

android - Appcelerator - 来自相机的图像为 Android 旋转 90 度

android - 将 ImageView 放置在居中按钮的左侧