Re: [Gambas-user] gb3: gb.opengl will not render alpha channel of 2D texture
Le Lundi 1 Août 2011 10:47:14, Benoît Minisini a écrit : Glu.Build2DMipmaps() could segfault if it receives a NULL image. Anyway, in revision #3958, you don't have to do all that trick: image alpha channel should be correctly taken into account in OpenGL APIs. Regards, Good catch! ++ -- BlackBerryreg; DevCon Americas, Oct. 18-20, San Francisco, CA The must-attend event for mobile developers. Connect with experts. Get tools for creating Super Apps. See the latest technologies. Sessions, hands-on labs, demos much more. Register early save! http://p.sf.net/sfu/rim-blackberry-1 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] Issue 75 in gambas: Split function problem
Status: New Owner: Labels: Version Type-Bug Priority-Medium OpSys-Any Dist-Any Arch-Any Desktop-Any GUI-Any New issue 75 by fabio.st...@gmail.com: Split function problem http://code.google.com/p/gambas/issues/detail?id=75 Split function problem Version: 2.21 Revision: Operating system: Linux Distribution: Ubuntu 11.05 Architecture: x86 GUI component: QT4 Desktop used: Gnome If I use Split on 1 2 3 4 5 DIM s AS String DIM sa AS String[] DIM i AS Integer s = 1 2 3 4 5 sa = NEW String[] sa = Split(s, ) FOR i = 0 TO sa.length - 1 PRINT i, sa[i] NEXT the output is: 0 1 1 2 2 3 3 4 4 5 If I use Split on 1 2 3 4 5 DIM s AS String DIM sa AS String[] DIM i AS Integer s = 1 2 3 4 5 sa = NEW String[] sa = Split(s, ) FOR i = 0 TO sa.length - 1 PRINT i, sa[i] NEXT the output is: 0... 1 1 2 2 3 3 4 4 5 5 Regards Fabio Sturman -- BlackBerryreg; DevCon Americas, Oct. 18-20, San Francisco, CA The must-attend event for mobile developers. Connect with experts. Get tools for creating Super Apps. See the latest technologies. Sessions, hands-on labs, demos much more. Register early save! http://p.sf.net/sfu/rim-blackberry-1 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Issue 75 in gambas: Split function problem
Updates: Status: Invalid Labels: -Version Version-2.22.0 Comment #1 on issue 75 by benoit.m...@gmail.com: Split function problem http://code.google.com/p/gambas/issues/detail?id=75 This behaviour is by design. Read the Split() documentation, and use its fourth optional argument to ignore void entries. -- BlackBerryreg; DevCon Americas, Oct. 18-20, San Francisco, CA The must-attend event for mobile developers. Connect with experts. Get tools for creating Super Apps. See the latest technologies. Sessions, hands-on labs, demos much more. Register early save! http://p.sf.net/sfu/rim-blackberry-1 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] gb3: public array that is dimensioned later
On 08/03/2011 07:00 PM, Kevin Fishburne wrote: I need to create a public array in a module but specify its dimensions in a procedure later. Is this possible, and how would it be done I forgot to mention, I'd like it to be a 2D array, though I could write workaround code if it has to be 1D. -- Kevin Fishburne Eight Virtues www: http://sales.eightvirtues.com e-mail: sa...@eightvirtues.com phone: (770) 853-6271 -- BlackBerryreg; DevCon Americas, Oct. 18-20, San Francisco, CA The must-attend event for mobile developers. Connect with experts. Get tools for creating Super Apps. See the latest technologies. Sessions, hands-on labs, demos much more. Register early save! http://p.sf.net/sfu/rim-blackberry-1 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] gb3: public array that is dimensioned later
On 08/03/2011 07:00 PM, Kevin Fishburne wrote: I need to create a public array in a module but specify its dimensions in a procedure later. Is this possible, and how would it be done I forgot to mention, I'd like it to be a 2D array, though I could write workaround code if it has to be 1D. You have to specify the array dimensions at the same time you create it. So you have to create it in your later procedure. Regards, -- Benoît Minisini -- BlackBerryreg; DevCon Americas, Oct. 18-20, San Francisco, CA The must-attend event for mobile developers. Connect with experts. Get tools for creating Super Apps. See the latest technologies. Sessions, hands-on labs, demos much more. Register early save! http://p.sf.net/sfu/rim-blackberry-1 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] gb3: public array that is dimensioned later
On 08/03/2011 08:09 PM, Benoît Minisini wrote: On 08/03/2011 07:00 PM, Kevin Fishburne wrote: I need to create a public array in a module but specify its dimensions in a procedure later. Is this possible, and how would it be done I forgot to mention, I'd like it to be a 2D array, though I could write workaround code if it has to be 1D. You have to specify the array dimensions at the same time you create it. So you have to create it in your later procedure. Hmmm. It's been my experience that public variables have to be declared at the top of a module outside of the procedures and that Dim needs to be used inside procedures. Is there some way around this? The variables which determine the number of dimensions of the array are calculated from values input by the user, but need to be persistent and accessible from multiple separate procedures. If it's not possible I'll make it 1D and use code so that it can be treated as 2D, dimensioning it to maximum realistic size when it's created. -- Kevin Fishburne Eight Virtues www: http://sales.eightvirtues.com e-mail: sa...@eightvirtues.com phone: (770) 853-6271 -- BlackBerryreg; DevCon Americas, Oct. 18-20, San Francisco, CA The must-attend event for mobile developers. Connect with experts. Get tools for creating Super Apps. See the latest technologies. Sessions, hands-on labs, demos much more. Register early save! http://p.sf.net/sfu/rim-blackberry-1 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] gb3: public array that is dimensioned later
On 08/03/2011 08:09 PM, Benoît Minisini wrote: On 08/03/2011 07:00 PM, Kevin Fishburne wrote: I need to create a public array in a module but specify its dimensions in a procedure later. Is this possible, and how would it be done I forgot to mention, I'd like it to be a 2D array, though I could write workaround code if it has to be 1D. You have to specify the array dimensions at the same time you create it. So you have to create it in your later procedure. Hmmm. It's been my experience that public variables have to be declared at the top of a module outside of the procedures and that Dim needs to be used inside procedures. Is there some way around this? The variables which determine the number of dimensions of the array are calculated from values input by the user, but need to be persistent and accessible from multiple separate procedures. If it's not possible I'll make it 1D and use code so that it can be treated as 2D, dimensioning it to maximum realistic size when it's created. Normal arrays are entirely dynamic. So you can declare the variable that will own the reference to the array somewhere: ' Module SomeWhere Public MyArray As Float[] ' Module SomeWhereElse Private Sub CreateArray(X As Integer, Y As Integer) SomeWhere.MyArray = new Float[X, Y] End Sub ' Module InAnotherDimension Private Sub DoSomeStuff() Dim X, Y As Integer X = SomeWhere.MyArray.Bounds[0] Y = SomeWhere.MyArray.Bounds[1] ... End -- Benoît Minisini -- BlackBerryreg; DevCon Americas, Oct. 18-20, San Francisco, CA The must-attend event for mobile developers. Connect with experts. Get tools for creating Super Apps. See the latest technologies. Sessions, hands-on labs, demos much more. Register early save! http://p.sf.net/sfu/rim-blackberry-1 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] gb.report gambas3
goodnight community would like to help me with gb.report I managed to do some reports in gambas3 but only funsion me with code creating them, I would like to design a graphical report and you look as designed, if you design a report to run it when you looks misconfigured. And also I have the problem that shows me all results of HRESULT ReportLabel just shows me a record and when I do it from the code for example: Cx As Connection Private Private rs As Result Public Sub _new () Dim i As ReportLabel cx = ModDB.conectar () rs = db.Exec (SELECT * FROM tbrecibo) i = New ReportLabel (RVBCont) For Each rs i = New ReportLabel (RVBCont) i.Text = rs!idrs!codigo_sociors!nombre_completo Next end when viewing the report does not look flashy aesthetic or misconfigured and if you look the way I want to show graphics with a reportlab as follows: Cx As Connection Private Private rs As Result Public Sub _new () Dim i As ReportLabel cx = ModDB.conectar () rs = db.Exec (SELECT * FROM tbrecibo) i = New ReportLabel (RVBCont) For Each rs ReportLabel1.Text = rs!id_completo ReportLabel2.Text = rs!codigo_socio ReportLabel3.Text = rs!nombre_completo Next end so just looking at a record are more than 100 could help me please. thanks -- BlackBerryreg; DevCon Americas, Oct. 18-20, San Francisco, CA The must-attend event for mobile developers. Connect with experts. Get tools for creating Super Apps. See the latest technologies. Sessions, hands-on labs, demos much more. Register early save! http://p.sf.net/sfu/rim-blackberry-1 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] gb3: public array that is dimensioned later
On 08/03/2011 09:03 PM, Benoît Minisini wrote: On 08/03/2011 08:09 PM, Benoît Minisini wrote: On 08/03/2011 07:00 PM, Kevin Fishburne wrote: I need to create a public array in a module but specify its dimensions in a procedure later. Is this possible, and how would it be done I forgot to mention, I'd like it to be a 2D array, though I could write workaround code if it has to be 1D. You have to specify the array dimensions at the same time you create it. So you have to create it in your later procedure. Hmmm. It's been my experience that public variables have to be declared at the top of a module outside of the procedures and that Dim needs to be used inside procedures. Is there some way around this? The variables which determine the number of dimensions of the array are calculated from values input by the user, but need to be persistent and accessible from multiple separate procedures. If it's not possible I'll make it 1D and use code so that it can be treated as 2D, dimensioning it to maximum realistic size when it's created. Normal arrays are entirely dynamic. So you can declare the variable that will own the reference to the array somewhere: ' Module SomeWhere Public MyArray As Float[] ' Module SomeWhereElse Private Sub CreateArray(X As Integer, Y As Integer) SomeWhere.MyArray = new Float[X, Y] End Sub ' Module InAnotherDimension Private Sub DoSomeStuff() Dim X, Y As Integer X = SomeWhere.MyArray.Bounds[0] Y = SomeWhere.MyArray.Bounds[1] ... End That is fantastic, thank you. It's amazing how little I really know about programming. I'm surprised I get as much accomplished as I do. :) -- Kevin Fishburne Eight Virtues www: http://sales.eightvirtues.com e-mail: sa...@eightvirtues.com phone: (770) 853-6271 -- BlackBerryreg; DevCon Americas, Oct. 18-20, San Francisco, CA The must-attend event for mobile developers. Connect with experts. Get tools for creating Super Apps. See the latest technologies. Sessions, hands-on labs, demos much more. Register early save! http://p.sf.net/sfu/rim-blackberry-1 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] gb3: gb.opengl - dynamically dimensioning a public 2D array of texture IDs
Previously I needed to create a 2D array of texture IDs. I couldn't get it to work worth a damn, so what I did instead was to create a texture Structure, then create an array of those structures. It works extremely well and allows me to store more information about each texture: ' Texture definition structure. Public Struct Texture Loaded As Boolean FileName As String ID As Integer[] SubID As Short Width As Short Height As Short LastUsed As Single End Struct ' Texture indices. Public tiObject[32768] As Struct Texture ' Assign some texture IDs. tiObject[1000].ID = Gl.GenTextures(16) I'm now trying to do the same thing but to create the array of structures dynamically in a procedure rather than at the beginning of a module. Doing this for a normal array works fine (thank you Benoît), but when I use the same syntax with a Structure it fails with various errors: Public tTileGrid[] As Struct Texture ' = fail. Public tTileGrid As Struct Texture[] ' = fail. If creating an array of structures that can be dimensioned in a later procedure is impossible, that is fine, but I'd like to know if there's a way to create a 2D array of OpenGL texture indices. Both methods would be terribly useful, actually. An OpenGL texture index is an array of Integers of undefined dimensions and is assigned values of 1...x when you call the Gl.GenTextures(x) function. For example, if I do this: Public TextureIDs[] As Integer TextureIDs = Gl.GenTextures(4) TextureIDs[0 - 3] will be 1, 2, 3 and 4. I tried assigning these numbers manually, but Gl.GenTextures() does something hidden (probably creates an internal index to accept the textures into VRAM) so it is a required call to be able to load the textures. I'm guessing I need a 2D array of 1D Integer arrays, so the 1D array will accept the results of Gl.GenTextures() and the 2D array will reference their coordinates in the array. If that is so, then what would the initial public declaration and subsequent procedural dimensioning look like? I think I have some kind of mild mental problem, as these things really make my head spin. FYI I'm doing a near total rewrite of the rendering pipeline in my game in order for it to use OpenGL as much as possible. Everything's been converted successfully except for landscape rendering, which is the most complex part. I expect my game to be broken for the next several days while I sort everything out. :/ -- Kevin Fishburne Eight Virtues www:http://sales.eightvirtues.com e-mail:sa...@eightvirtues.com phone: (770) 853-6271 -- BlackBerryreg; DevCon Americas, Oct. 18-20, San Francisco, CA The must-attend event for mobile developers. Connect with experts. Get tools for creating Super Apps. See the latest technologies. Sessions, hands-on labs, demos much more. Register early save! http://p.sf.net/sfu/rim-blackberry-1 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user