Bug 3487 - Invalid method parameter for GetActiveUniform and GetActiveAttrib
Summary: Invalid method parameter for GetActiveUniform and GetActiveAttrib
Status: RESOLVED FIXED
Alias: None
Product: iOS
Classification: Xamarin
Component: Xamarin.iOS.dll ()
Version: 5.2
Hardware: PC Windows
: --- normal
Target Milestone: Untriaged
Assignee: Rolf Bjarne Kvinge [MSFT]
URL:
Depends on:
Blocks:
 
Reported: 2012-02-15 16:28 UTC by Ryan Austin
Modified: 2012-02-27 18:52 UTC (History)
4 users (show)

Tags:
Is this bug a regression?: ---
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.


Please create a new report on Developer Community or GitHub with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
RESOLVED FIXED

Description Ryan Austin 2012-02-15 16:28:20 UTC
The OpenTK based methods GetActiveUniform and GetActiveAttrib in the OpenTK.Graphics.ES20.GL namespace of the MonoTouch library have an invalid final parameter.

They both take a string for parameter 'name' while these functions are intended to return the name of the shader uniform or attribute being queried. The Windows OpenTK 1.0 versions of these methods take a StringBuilder as the name parameter. The base OpenGLES functions take a char* for this parameter.

[OpenTK.AutoGenerated(Category="2.0", EntryPoint="glGetActiveUniform", Version="2.0")]
public static void GetActiveUniform (int program, int index, int bufsize, ref int length, ref int size, ref All type, string name)

[OpenTK.AutoGenerated(Category="2.0", EntryPoint="glGetActiveAttrib", Version="2.0")]
public static void GetActiveAttrib (int program, int index, int bufsize, ref int length, ref int size, ref All type, string name)
Comment 1 Kris 2012-02-23 19:44:47 UTC
This bug breaks the ES20 API as you have no way to get the names of these attributes dynamically.  This is also related to many other differences from the OpenTK 1.0 standard.  See bug 3330.
Comment 2 Rolf Bjarne Kvinge [MSFT] 2012-02-27 18:20:15 UTC
Fixed (fea26173 master).

This will be included in the upcoming 5.3 beta - note that I've created a new OpenTK-1.0.dll assembly which contains the new (backwards incompatible) API.

OpenTK.dll will continue to exist, but with the old API.
Comment 3 Ryan Austin 2012-02-27 18:43:13 UTC
Thanks Rolf! For the record, this issue existed in MonoDroid too, do I need to enter a separate bug for that?
Comment 4 Rolf Bjarne Kvinge [MSFT] 2012-02-27 18:52:35 UTC
Yes, you should open a separate bug for MfA bugs. If you want to try this out I've attached the new OpenTK-1.0.dll in bug #3300.