我已经下载了googlesamples:vulkan-basic-samples,编译并执行了这些示例。但是,我发现所有这些样本都在NativeActivity
中指定了AndroidManifest.xml
,例如:
<!-- Our activity is the built-in NativeActivity framework class.
This will take care of integrating with our NDK code. -->
<activity android:name="android.app.NativeActivity"
android:label="@string/app_name"
android:configChanges="orientation|keyboardHidden">
<!-- Tell NativeActivity the name of or .so -->
<meta-data android:name="android.app.lib_name"
android:value="vulkan_samples" />
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>
但我想使用自己的Activity(在Java中),请告诉我如何。 谢谢!