[Gambas-user] SDL Bug

2016-11-03 Thread Shane

I Think there id a bug in the SDL Image.Copy method when used it is

not working as expected and when you try to copy a large amount of Image

it crashes this program.


[System]
Gambas=3.9.1
OperatingSystem=Linux
Kernel=4.4.0-45-generic
Architecture=x86_64
Distribution=Linux Mint 17.2 Rafaela
Desktop=MATE
Theme=Gtk
Language=en_AU.UTF-8
Memory=3805M

[Libraries]
Cairo=libcairo.so.2.11301.0
Curl=libcurl.so.4.3.0
DBus=libdbus-1.so.3.7.6
GStreamer=libgstreamer-0.10.so.0.30.0
GStreamer=libgstreamer-1.0.so.0.204.0
GTK+2=libgtk-x11-2.0.so.0.2400.23
GTK+3=libgtk-3.so.0.1000.8
OpenGL=libGL.so.1.2.0
Poppler=libpoppler.so.44.0.0
QT4=libQtCore.so.4.8.6
QT5=libQt5Core.so.5.2.1
SDL=libSDL-1.2.so.0.11.4
SQLite=libsqlite3.so.0.8.6

[Environment]
DBUS_SESSION_BUS_ADDRESS=unix:abstract=/tmp/dbus-JwdfcZ1nfu,guid=082f2df3f4d886742a97b567581bb58e
DEFAULTS_PATH=/usr/share/gconf/mate.default.path
DESKTOP_SESSION=mate
DISPLAY=:0.0
GB_GUI=gb.qt4
GDMSESSION=mate
GDM_XSERVER_LOCATION=local
GNOME_KEYRING_CONTROL=/run/user/1000/keyring-mknkPE
GNOME_KEYRING_PID=1957
GPG_AGENT_INFO=/run/user/1000/keyring-mknkPE/gpg:0:1
HOME=/home/
LANG=en_AU.UTF-8
LOGNAME=
MANDATORY_PATH=/usr/share/gconf/mate.mandatory.path
MATE_DESKTOP_SESSION_ID=this-is-deprecated
MDMSESSION=mate
MDM_LANG=en_AU.UTF-8
MDM_XSERVER_LOCATION=local
PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games
PWD=/home/
SESSION_MANAGER=local/:@/tmp/.ICE-unix/1711,unix/:/tmp/.ICE-unix/1711
SHELL=/bin/bash
SSH_AGENT_PID=1867
SSH_AUTH_SOCK=/run/user/1000/keyring-mknkPE/ssh
TEXTDOMAIN=im-config
TEXTDOMAINDIR=/usr/share/locale/
TZ=:/etc/localtime
USER=
USERNAME=
WINDOWPATH=8
XAUTHORITY=/home//.Xauthority
XDG_CONFIG_DIRS=/etc/xdg/xdg-mate:/etc/xdg
XDG_CURRENT_DESKTOP=MATE
XDG_DATA_DIRS=/usr/share/mate:/usr/local/share/:/usr/share/:/usr/share/mdm/
XDG_RUNTIME_DIR=/run/user/1000
XDG_SEAT=seat0
XDG_SESSION_COOKIE=139d2632112d070b9e811bbc561842ce-1478210956.123282-1196872275
XDG_SESSION_DESKTOP=mate
XDG_SESSION_ID=c1
XDG_VTNR=8



SdlTest-0.0.1.tar.gz
Description: application/gzip
--
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today. http://sdm.link/xeonphi___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] Flyer Invasion Game - And a possible bug-report

2016-11-03 Thread Shane
If I set resizeable=True it works as expected



On 03/11/16 19:07, Moviga Technologies wrote:
> Thank you!
>
> Are you running Wayland? There's no built in way to detect screen
> resolution for that (yet). But, why it apparently increases the
> resolution outside the borders of the window when you click outside, I
> have no idea why? A SDL bug?
>
>
> Den 03. nov. 2016 03:44, skrev Shane:
>> there were pics
>>
>>
>>
>> On 02/11/16 17:46, Moviga Technologies wrote:
>>> Please rephrase what you said?
>>>
>>>
>>> Den 02. nov. 2016 02:29, skrev Shane:
 this is what i get with your latest version

 and when i click away and come back


 On 02/11/16 07:11, Benoît Minisini wrote:
> Le 31/10/2016 à 13:51, Moviga Technologies a écrit :
>> Hi!
>>
>> This weekend I had some fun making a simple game in SDL that you can
>> find on the farm, or download here:
>> http://forum.gambas.one/download/file.php?id=12
>>
>> There is a warning in the console in the Gambas IDE that says:
>> gbx3: warning: 2 allocation(s) non freed.
>> Not sure where that comes from, but as C++ needs to free up stuff, I
>> suppose it has to do with the gb.sdl2 component?
>>
> It should be fixed in revision #7952. It was related to gb.sdl2.audio.
>
> Regards,
>
 --

 Developer Access Program for Intel Xeon Phi Processors
 Access to Intel Xeon Phi processor-based developer platforms.
 With one year of Intel Parallel Studio XE.
 Training and support from Colfax.
 Order your platform today. http://sdm.link/xeonphi
 ___
 Gambas-user mailing list
 Gambas-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/gambas-user
>>> --
>>>
>>> Developer Access Program for Intel Xeon Phi Processors
>>> Access to Intel Xeon Phi processor-based developer platforms.
>>> With one year of Intel Parallel Studio XE.
>>> Training and support from Colfax.
>>> Order your platform today. http://sdm.link/xeonphi
>>> ___
>>> Gambas-user mailing list
>>> Gambas-user@lists.sourceforge.net
>>> https://lists.sourceforge.net/lists/listinfo/gambas-user
>>
>>
>> --
>> Developer Access Program for Intel Xeon Phi Processors
>> Access to Intel Xeon Phi processor-based developer platforms.
>> With one year of Intel Parallel Studio XE.
>> Training and support from Colfax.
>> Order your platform today. http://sdm.link/xeonphi
>>
>>
>> ___
>> Gambas-user mailing list
>> Gambas-user@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/gambas-user
> --
> Developer Access Program for Intel Xeon Phi Processors
> Access to Intel Xeon Phi processor-based developer platforms.
> With one year of Intel Parallel Studio XE.
> Training and support from Colfax.
> Order your platform today. http://sdm.link/xeonphi
> ___
> Gambas-user mailing list
> Gambas-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/gambas-user


--
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today. http://sdm.link/xeonphi
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] MediaPlayer bug with AboutToFinish and URL?

2016-11-03 Thread Benoît Minisini
Le 03/11/2016 à 13:45, Benoît Minisini a écrit :
> Le 03/11/2016 à 12:02, Piper984 a écrit :
>> Hi Benoît,
>>
>> Just a quick update: I tried running my sample application on a newly
>> installed Ubuntu 16.04, and with my reference video clips and all is
>> working as expected!  Thanks a ton!
>>
>> Of interest, and perhaps some source of issues: Some of the video clips I
>> have for testing (Sintel and Big Buck Bunny trailers in .webm and
>> .mp4) will
>> not 'end' correctly and so the next video clip doesn't load.  *BUT* the
>> actual video clips I want to use (h264 clips converted to MP4 via MP4Box)
>> for my application do work.  gb.media plays them successfully, and when
>> .NextURL is set from the AboutToFinish event then the next video clip is
>> loaded and rendered gaplessly!  Huzzah!
>>
>> So: Thanks for helping with this Benoît.  I appreciate it, as I can
>> dev my
>> application in Gambas now and not Python/C++/Glade GTK tools.
>>
>> Best regards!
>>
>
> As I said, all that seems to heavily depend on which GStreamer version
> you use. I just hope that things becomes more stable with new versions
> of the library!
>
> FYI, the next GStreamer version introduces (again) a new media player
> plugin. So cross your fingers...
>

By the way, thanks for your big early X-Mas gift!

-- 
Benoît Minisini

--
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today. http://sdm.link/xeonphi
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] MediaPlayer bug with AboutToFinish and URL?

2016-11-03 Thread Benoît Minisini
Le 03/11/2016 à 12:02, Piper984 a écrit :
> Hi Benoît,
>
> Just a quick update: I tried running my sample application on a newly
> installed Ubuntu 16.04, and with my reference video clips and all is
> working as expected!  Thanks a ton!
>
> Of interest, and perhaps some source of issues: Some of the video clips I
> have for testing (Sintel and Big Buck Bunny trailers in .webm and .mp4) will
> not 'end' correctly and so the next video clip doesn't load.  *BUT* the
> actual video clips I want to use (h264 clips converted to MP4 via MP4Box)
> for my application do work.  gb.media plays them successfully, and when
> .NextURL is set from the AboutToFinish event then the next video clip is
> loaded and rendered gaplessly!  Huzzah!
>
> So: Thanks for helping with this Benoît.  I appreciate it, as I can dev my
> application in Gambas now and not Python/C++/Glade GTK tools.
>
> Best regards!
>

As I said, all that seems to heavily depend on which GStreamer version 
you use. I just hope that things becomes more stable with new versions 
of the library!

FYI, the next GStreamer version introduces (again) a new media player 
plugin. So cross your fingers...

-- 
Benoît Minisini

--
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today. http://sdm.link/xeonphi
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] MediaPlayer bug with AboutToFinish and URL?

2016-11-03 Thread Piper984
Hi Benoît,

Just a quick update: I tried running my sample application on a newly
installed Ubuntu 16.04, and with my reference video clips and all is
working as expected!  Thanks a ton!  

Of interest, and perhaps some source of issues: Some of the video clips I
have for testing (Sintel and Big Buck Bunny trailers in .webm and .mp4) will
not 'end' correctly and so the next video clip doesn't load.  *BUT* the
actual video clips I want to use (h264 clips converted to MP4 via MP4Box)
for my application do work.  gb.media plays them successfully, and when
.NextURL is set from the AboutToFinish event then the next video clip is
loaded and rendered gaplessly!  Huzzah!  

So: Thanks for helping with this Benoît.  I appreciate it, as I can dev my
application in Gambas now and not Python/C++/Glade GTK tools.

Best regards!



--
View this message in context: 
http://gambas.8142.n7.nabble.com/MediaPlayer-bug-with-AboutToFinish-and-URL-tp57513p57714.html
Sent from the gambas-user mailing list archive at Nabble.com.

--
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today. http://sdm.link/xeonphi
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] a possible bug-report

2016-11-03 Thread Benoît Minisini
Le 03/11/2016 à 08:42, Rolf-Werner Eilert a écrit :
>
> Am 31.10.2016 13:51, schrieb Moviga Technologies:
>> Hi!
>>
>> There is a warning in the console in the Gambas IDE that says:
>> gbx3: warning: 2 allocation(s) non freed.
>> Not sure where that comes from, but as C++ needs to free up stuff, I
>> suppose it has to do with the gb.sdl2 component?
>>
>>
>
> Just saw this thread, and there is a similar problem with one of my
> Gambas hacks. Every 10 minutes, the program calls the email server of
> our website and asks for application forms that might have been sent. If
> there is one, it processes the data and makes a nice PDF which is then
> sent to the customer.
>
> If the webserver fails in that moment or there is no internet
> connection, the program stops and sends me a system mail with "3
> allocations non freed".
>
> I have never found the reason, and it didn't really bother me, but if
> someone is interested in finding out, I would post some code and start
> looking for it...
>
> Regards
> Rolf
>

For that I need a project that reproduces the problem.

-- 
Benoît Minisini

--
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today. http://sdm.link/xeonphi
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] Val function changed behaviour, porting gambas2 to gambas3

2016-11-03 Thread Fabien Bodard
>
> No problem, Benoit, I see the advantages. After all, my problem was due
> to sloppy programming... ;)
>
> But in BASIC, one is used to everything being converted from one format
> to another without raising an error that can stop the program. So in
> normal BASIC thinking, if val() cannot find a value in a string, it
> would be expected to send "0", though it isn't fully logical I have to
> admit. In the scope of my programming, this would do the job. Maybe I
> should make my own Val()...
>
> Regards
> Rolf
>


Val() return Null because 0 is a valid result. So with Null we know
that the converting fail.

Regards
-- 
Fabien Bodard

--
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today. http://sdm.link/xeonphi
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] Flyer Invasion Game - And a possible bug-report

2016-11-03 Thread Moviga Technologies
Thank you!

Are you running Wayland? There's no built in way to detect screen 
resolution for that (yet). But, why it apparently increases the 
resolution outside the borders of the window when you click outside, I 
have no idea why? A SDL bug?


Den 03. nov. 2016 03:44, skrev Shane:
> there were pics
>
>
>
> On 02/11/16 17:46, Moviga Technologies wrote:
>> Please rephrase what you said?
>>
>>
>> Den 02. nov. 2016 02:29, skrev Shane:
>>> this is what i get with your latest version
>>>
>>> and when i click away and come back
>>>
>>>
>>> On 02/11/16 07:11, Benoît Minisini wrote:
 Le 31/10/2016 à 13:51, Moviga Technologies a écrit :
> Hi!
>
> This weekend I had some fun making a simple game in SDL that you can
> find on the farm, or download here:
> http://forum.gambas.one/download/file.php?id=12
>
> There is a warning in the console in the Gambas IDE that says:
> gbx3: warning: 2 allocation(s) non freed.
> Not sure where that comes from, but as C++ needs to free up stuff, I
> suppose it has to do with the gb.sdl2 component?
>
 It should be fixed in revision #7952. It was related to gb.sdl2.audio.

 Regards,

>>> --
>>>  
>>>
>>> Developer Access Program for Intel Xeon Phi Processors
>>> Access to Intel Xeon Phi processor-based developer platforms.
>>> With one year of Intel Parallel Studio XE.
>>> Training and support from Colfax.
>>> Order your platform today. http://sdm.link/xeonphi
>>> ___
>>> Gambas-user mailing list
>>> Gambas-user@lists.sourceforge.net
>>> https://lists.sourceforge.net/lists/listinfo/gambas-user
>>
>> --
>>  
>>
>> Developer Access Program for Intel Xeon Phi Processors
>> Access to Intel Xeon Phi processor-based developer platforms.
>> With one year of Intel Parallel Studio XE.
>> Training and support from Colfax.
>> Order your platform today. http://sdm.link/xeonphi
>> ___
>> Gambas-user mailing list
>> Gambas-user@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/gambas-user
>
>
>
> --
> Developer Access Program for Intel Xeon Phi Processors
> Access to Intel Xeon Phi processor-based developer platforms.
> With one year of Intel Parallel Studio XE.
> Training and support from Colfax.
> Order your platform today. http://sdm.link/xeonphi
>
>
> ___
> Gambas-user mailing list
> Gambas-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/gambas-user

--
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today. http://sdm.link/xeonphi
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] a possible bug-report

2016-11-03 Thread Rolf-Werner Eilert

Am 31.10.2016 13:51, schrieb Moviga Technologies:
> Hi!
>
> There is a warning in the console in the Gambas IDE that says:
> gbx3: warning: 2 allocation(s) non freed.
> Not sure where that comes from, but as C++ needs to free up stuff, I
> suppose it has to do with the gb.sdl2 component?
>
>

Just saw this thread, and there is a similar problem with one of my 
Gambas hacks. Every 10 minutes, the program calls the email server of 
our website and asks for application forms that might have been sent. If 
there is one, it processes the data and makes a nice PDF which is then 
sent to the customer.

If the webserver fails in that moment or there is no internet 
connection, the program stops and sends me a system mail with "3 
allocations non freed".

I have never found the reason, and it didn't really bother me, but if 
someone is interested in finding out, I would post some code and start 
looking for it...

Regards
Rolf


--
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today. http://sdm.link/xeonphi
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] Val function changed behaviour, porting gambas2 to gambas3

2016-11-03 Thread Rolf-Werner Eilert

Am 02.11.2016 17:16, schrieb Benoît Minisini:
> Le 02/11/2016 à 16:49, Rolf-Werner Eilert a écrit :
>> The new behaviour of val() drove me nuts when it appeared first ;) I had
>> used it in so many places, and all over my code. Sometimes it lasts for
>> weeks until your program hits this place, and AGAIN val() Arrgh... :)
>>
>> So in most cases, I ended up either checking for null before (somewhat
>> roundabout) or just using CInt() instead.
>>
>> Regards
>> Rolf
>>
> This change was needed, because Val() now takes thousand separators into
> account, and some language uses spaces for that.
>
> Regards,
>

No problem, Benoit, I see the advantages. After all, my problem was due 
to sloppy programming... ;)

But in BASIC, one is used to everything being converted from one format 
to another without raising an error that can stop the program. So in 
normal BASIC thinking, if val() cannot find a value in a string, it 
would be expected to send "0", though it isn't fully logical I have to 
admit. In the scope of my programming, this would do the job. Maybe I 
should make my own Val()...

Regards
Rolf


--
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today. http://sdm.link/xeonphi
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user