This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Shader Development Studio Problem

Note: This was originally posted on 12th May 2011 at http://forums.arm.com

Hello,
Recently I decided to try out Mali Developer Tools, which look very promising.

Unfortunately I have a problem with Shader Development Studio.
When trying to make SimpleTest Project (from the User Guide) while rendering the shader effect
the Shader Preview shows a triangle instead of a square shown in the Guide.
In general, it is not surprising, since the option VERTICES in Shader Attributes View has by default  three
vertices:
-1.0 -1.0,0.0,1.0,
1.0 -1.0,0.0,1.0,
1.0,1.0,0.0,1.0,

The problem however is that there is no possibility to add additional vertices
(when choosing the option USER_DEFINED). You can only change the three given.
Changing the geometry in Shader Control View do not bring any effect, always showing three vertices.
Even when using a Shader Examples from Mali GPU Shader Library shaders are applied to that triangle.
The shaders themselves are working (changing color, texturing, etc).

Plugin has been tested on the following configurations:
Eclipse 3.6.2
  • GeForce 9600M GT Windows 7 64bit
  • GeForce GTS 250 Windows 7 32bit

All necessary OpenGL extensions are present, Emulator and Offline Shader Compiler are installed and work.

[font=arial, sans-serif]Had someone the same problem and is there a solution?[/font]
[font=arial, sans-serif]Thanks.[/font]
Parents
  • Note: This was originally posted on 26th March 2013 at http://forums.arm.com

    Hey Shapkin,

    Excellent detective work! I can now reproduce this here.

    You are correct, the system local setting is the root cause. I've looked into the code and can provide an explanation for the behaviour:
    • The geometry files contain the vertex data as floating-point with a '.' separator
    • An instance of a java.util.Scanner is used to parse that data
    • The scanner will pick up the current system locale and use that to interpret the floating point number
    That's all well, but on systems that do not have "." as a floating-point separator, an exception will be thrown that forces the geometry back to a triangle. The workaround is to, as you say, change to a locale that has a "." separator.

    Many thanks for finding and reporting this issue!
Reply
  • Note: This was originally posted on 26th March 2013 at http://forums.arm.com

    Hey Shapkin,

    Excellent detective work! I can now reproduce this here.

    You are correct, the system local setting is the root cause. I've looked into the code and can provide an explanation for the behaviour:
    • The geometry files contain the vertex data as floating-point with a '.' separator
    • An instance of a java.util.Scanner is used to parse that data
    • The scanner will pick up the current system locale and use that to interpret the floating point number
    That's all well, but on systems that do not have "." as a floating-point separator, an exception will be thrown that forces the geometry back to a triangle. The workaround is to, as you say, change to a locale that has a "." separator.

    Many thanks for finding and reporting this issue!
Children
No data