Using the Framework

Hi all,

I am new with the PowerVR SDK and android NDK,
so i use VisualGDB in vs2013 for learning , wheter here ever use VisualGDB with PowerVR for developt mobile application ?
I’m stuck including the framework in my project it say error : undefined reference to `pvr::platform::shell::exitShell()’ C:\Imagination\PowerVR_Graphics\PowerVR_SDK\SDK_2016_R2\Framework\PVRShell\Shell.h . Must I build each framework in order to use framework ?

Hello Jans,

wheter here ever use VisualGDB with PowerVR for developt mobile application ?
Could you please reformulate this question ?

As per your second question:
Must I build each framework in order to use framework ?
The answer is: yes.
You must build the framework components your project relies on.
In your case, your program references a PVRShell function (pvr::platform::shell::exitShell()) therefore you need to add the PVRShell project to your solution as well as set the solution’s dependencies. You can do so using the configuration properties window shown below:

[attachment file=54964]

Theo

Sorry I don’t know english very well,

I mean does anyone here have used visualGDB with PowerVR SDK to developt their android application ,
if yes ,that can may help with my problem.

I will try to build the framework

when i try to build PVRShell it always say

IntelliSense: “__m128” is not a type name c:\Imagination\PowerVR_Graphics\PowerVR_SDK\SDK_2016_R2\External\glm\detail\intrinsic_common.hpp

error MSB3073: The command ““C:\Program Files (x86)\Sysprogs\VisualGDB\VisualGDB.exe” /build “E:\vs2013\test\PVRShell\PVRShell.vcxproj” “/solution:E:\vs2013\test\test.sln” “/config:Debug” “/platform:ARM”” exited with code 1. C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.MakeFile.Targets 38 5 PVRShell

no we haven’t used visualGDB or heared anyone using it with the framework.
to build android we use gradle. this is true for ogles & vulkan.
we use linux/ windows for development and then deploy to android.
since you are using it for education purpose you could focus on windows with visual studio or on xcode if you use apple. the setup is pretty much painless.

visual studio 2015 supports android projects but we had problem with debugging some complex code in our framework. so i would rather focus on windows or apple if i were you. you could do it with linux but not sure how good you are using gdb on linux.

Hello Jans,

Your compiler is complaining because __m128 is a vector type used by SSE instuctions, These instructions are x86 specific (not ARM)

Could you please tell us your visual studio version?
We believe your project configuration is still set to build a win32 project.
As a result, glm wrongly enables SSE.

[quote quote=54976]Could you please tell us your visual studio version?
We believe your project configuration is still set to build a win32 project.
As a result, glm wrongly enables SSE.

[/quote]

I am using VisualStudio 2013 Update 5 ,
The project setting is win32 but the toolchain target is armv8-64
is there any Preprocessor directives that can i change to disable SSE

Can I ask you what the target patform is? Is it android, Windows 10 on arm? …

the target platform is win32 , but i have change to ARM and try to build PVRCore but have this error

[scode lang="{c}"][arm64-v8a] Compile++ : PVRCore <= BufferStream.cpp
1>C:\Imagination\PowerVR_Graphics\PowerVR_SDK\SDK_2016_R2\Framework\PVRCore\BufferStream.cpp(11,27): error : PVRCore/Maths.h: No such file or directory
1> #include "PVRCore/Maths.h"
1> ^
1> compilation terminated.
1> make: *** [obj/local/arm64-v8a/objs/PVRCore/BufferStream.o] Error 1
1> -------------------------------------------------------------
1> Command exited with code 2
1> Executable: E:\Program\android-ndk-r12b\ndk-build.cmd
1> Arguments: NDK_DEBUG=0 APP_PLATFORM=android-21 VGDB_VSCONFIG=Release
1> Directory: E:\vs2013\AndroidProject2\AndroidProject2[/scode]

this is the makefile

[scode lang="{c}"]LOCAL_PATH := $(PVRSDKDIR)/Framework/PVRCore
PVRFRAMEWORKDIR := $(realpath $(PVRSDKDIR)/Framework/)

include $(CLEAR_VARS)

LOCAL_MODULE := PVRCore
LOCAL_SRC_FILES := $(notdir $(wildcard $(LOCAL_PATH)/.cpp))
$(addprefix Android/, $(notdir $(wildcard $(LOCAL_PATH)/Android/
.cpp)))
…/…/External/pugixml/pugixml.cpp

LOCAL_CFLAGS := $(SDK_BUILD_FLAGS) -DPUGIXML_NO_EXCEPTIONS
LOCAL_C_INCLUDES := $(PVRFRAMEWORKDIR) $(PVRFRAMEWORKDIR)/…/Builds/Include/

include $(BUILD_STATIC_LIBRARY)[/scode]

I can pass the error with delete the PVRCore prefix in the include but thats to many

lucky I successfully build the framework library and success deploy the application in android.
Thanks You @Theo to help me, the problem is solved now.
the only problem now is the intellisense still give an error even though the compile process with nmake is success.

Hi Jans,
I’m you found a way to compile your project.

Can you build it from within visual studio? Would you prefer that over a makefile?

Best,
Theo

What is the other ways to compile the project ?

I can compile the project with visualstudio using visualGDB with modifiying the android makefile,
the instellisense is give that wrong SSE target error and another error but i can still compile the project

Hello Jans,

I have never used VisualGDB.
As senthuranukr said, the PowerVR sdk is built using gradle when targeting android platforms.

Here are our suggestion (listed in order of preference):

1: visual studio 15 supports android project files. but you have to create an android project file for each framework library and example from scratch. This will fix your worries about the intellisense.

2: use gradle: use gradle to build the apk. you can deploy it but you can’t debug it.

3: Disable the instellisense if you don’t care.

Also changing the toolchain may not change the ide behaviour entirly. If you want to get the ide to do what you want, the project must be entirely configured. We suggest you create the android project for each of the libraries and for the examples. Makefiles are not equivalent to visual studio project configuration and might in some cases not be enough. We hope this helps.

[quote quote=54993]Hello Jans,

I have never used VisualGDB.
As senthuranukr said, the PowerVR sdk is built using gradle when targeting android platforms.

Here are our suggestion (listed in order of preference):

1: visual studio 15 supports android project files. but you have to create an android project file for each framework library and example from scratch. This will fix your worries about the intellisense.

2: use gradle: use gradle to build the apk. you can deploy it but you can’t debug it.

3: Disable the instellisense if you don’t care.

Also changing the toolchain may not change the ide behaviour entirly. If you want to get the ide to do what you want, the project must be entirely configured. We suggest you create the android project for each of the libraries and for the examples. Makefiles are not equivalent to visual studio project configuration and might in some cases not be enough. We hope this helps.

[/quote]

Thanks You , I will try that next time if there is a problem that is difficult resolved with visualstudio