android
  #21  
Old 01-14-2010, 10:47 AM
ThievingSix ThievingSix is offline
Member
 
Join Date: Aug 2008
Posts: 218
Default

I was hoping for access to the screen buffer for screenshot type code but it seems it's not supported.
Reply With Quote

Advertisement [Remove Advertisement]

  #22  
Old 01-14-2010, 03:36 PM
kushndonuts kushndonuts is offline
Junior Member
 
Join Date: Jan 2010
Location: Maryland
Posts: 29
Default

I wonder if screenshot support could be added by creative through a firmware upgrade.
Reply With Quote

  #23  
Old 01-14-2010, 04:09 PM
ThievingSix ThievingSix is offline
Member
 
Join Date: Aug 2008
Posts: 218
Default

Oh I can pretty much guarantee it. Getting screen data is a must for games that want to be proficient.
Reply With Quote

  #24  
Old 01-14-2010, 04:12 PM
kushndonuts kushndonuts is offline
Junior Member
 
Join Date: Jan 2010
Location: Maryland
Posts: 29
Default

Cool
Here's Paint v0.1 Alpha
Download: http://www.divshare.com/download/10174777-de8
Reply With Quote

  #25  
Old 01-14-2010, 04:46 PM
bzdbbb's Avatar
bzdbbb bzdbbb is offline
X-Fi2 Development Moderator
 
Join Date: Dec 2009
Location: Gloucestershire, UK
Posts: 94
Default

Kwl - I like it, it has a kind of etch-a-sketch quality. I have a couple of suggestions for the next version :P

>Make the buttons slightly wider, I have a protective case and it took me several attempts to get it to touch

>The lag is unfortunately something that there is no way to get rid of (see the back & forth in my thread) but you're using os.sleep(4), you can probably get away with a lower value..

Other than that it's a very good addition to the available apps - what with ThievingSix and Jan_DK's releases mainly being experimental, and mine all being games
Reply With Quote

  #26  
Old 01-14-2010, 05:19 PM
Jan_DK's Avatar
Jan_DK Jan_DK is offline
Junior Member
 
Join Date: Mar 2009
Location: Denmark
Posts: 88
Default

I'm getting flashbacks from a year ago when I was beginning programming
the Cowon O2 in C, one of the demo's I made was this draw thingy.

It just load a image as background and 3 brush images in different colours
and change them via the volume buttons, and then you just draw and get this weird 3d effect: maybe this could be in Paint 2.0


Screenshot from the O2 dated 1303-2009: yes you can do that on the O2 Creative !


Jan_DK
Reply With Quote

  #27  
Old 01-14-2010, 06:17 PM
kushndonuts kushndonuts is offline
Junior Member
 
Join Date: Jan 2010
Location: Maryland
Posts: 29
Default

Quote:
>Make the buttons slightly wider, I have a protective case and it took me several attempts to get it to touch

>The lag is unfortunately something that there is no way to get rid of (see the back & forth in my thread) but you're using os.sleep(4), you can probably get away with a lower value..
I'll work on that after I take my Oracle 2 (PL/SQL) Final which is in a few days.

Btw I just started programing in Lua a few days ago and I think that it is the easiest language out there
Reply With Quote

  #28  
Old 01-14-2010, 06:23 PM
ThievingSix ThievingSix is offline
Member
 
Join Date: Aug 2008
Posts: 218
Default

Lol, I'm going to take a guess but we all started lua because of the XFi2
Reply With Quote

  #29  
Old 01-14-2010, 06:59 PM
kushndonuts kushndonuts is offline
Junior Member
 
Join Date: Jan 2010
Location: Maryland
Posts: 29
Default

yeah pretty much
Reply With Quote

  #30  
Old 01-15-2010, 01:59 AM
ThievingSix ThievingSix is offline
Member
 
Join Date: Aug 2008
Posts: 218
Default

Quote:
Originally Posted by Jan_DK View Post
After discovering that os.sleep() don't take milliseconds but units of 10ms
i wanted to change the os.sleep(1) = wait 10ms to os.wait(1) = wait 1 ms
in the Starfield screensaver to speed it up, i got the speed-up, but
after changing that, I could not exit the apps. only reset works, so
I guess that the control event thingy in the X-Fi2 needs at least 10ms
to work, even the power off button.


Jan_DK
I was just testing os.wait(1) as well and I did not run into this problem. Might there be another reason?

Edit: Odd...I just tried no sleep or wait in my application and I didn't run into any problems like I had before. Weird.
Reply With Quote

  #31  
Old 01-15-2010, 09:59 AM
Jan_DK's Avatar
Jan_DK Jan_DK is offline
Junior Member
 
Join Date: Mar 2009
Location: Denmark
Posts: 88
Default

Quote:
Originally Posted by ThievingSix View Post
I was just testing os.wait(1) as well and I did not run into this problem. Might there be another reason?

Edit: Odd...I just tried no sleep or wait in my application and I didn't run into any problems like I had before. Weird.
Sound strange,,,

Right now I'm playing with Pong and line 335 os.sleep(2) = 20ms delay
to os.wait(10) 10 ms. delay.

Using os.wait(10) the game main menu acts normal.
using os.wait(9) the game main menu do no respond, only way out is reset.


Jan_DK

Last edited by Jan_DK; 01-15-2010 at 10:06 AM. Reason: error
Reply With Quote

  #32  
Old 01-15-2010, 10:28 AM
Jan_DK's Avatar
Jan_DK Jan_DK is offline
Junior Member
 
Join Date: Mar 2009
Location: Denmark
Posts: 88
Default

Quote:
Originally Posted by ThievingSix View Post
Lol, I'm going to take a guess but we all started lua because of the XFi2
I started beginning programming in C be course of the Cowon O2
and bought the book 'C programming -A modern approach"

My latest book is 'Beginning Lua Programming' by Kurt Jung
so it's not a wild guess.


Jan_DK
Reply With Quote

  #33  
Old 01-15-2010, 12:09 PM
bzdbbb's Avatar
bzdbbb bzdbbb is offline
X-Fi2 Development Moderator
 
Join Date: Dec 2009
Location: Gloucestershire, UK
Posts: 94
Default

Quote:
Lol, I'm going to take a guess but we all started lua because of the XFi2
Yep

It's my favorate language now, it's so simple yet so powerful
Reply With Quote

  #34  
Old 01-15-2010, 12:41 PM
ThievingSix ThievingSix is offline
Member
 
Join Date: Aug 2008
Posts: 218
Default

Quote:
Originally Posted by Jan_DK View Post
Sound strange,,,

Right now I'm playing with Pong and line 335 os.sleep(2) = 20ms delay
to os.wait(10) 10 ms. delay.

Using os.wait(10) the game main menu acts normal.
using os.wait(9) the game main menu do no respond, only way out is reset.


Jan_DK
Uploaded the newest Apeopex sample that works without sleep or wait. It might have to do with how the Event loop is either: A) In a module, or B) Just in a different function. The good thing is I'm getting no input lag from the touch.move() event which seems to be the bottleneck for everyone(including pong).
Reply With Quote

  #35  
Old 01-15-2010, 01:06 PM
bzdbbb's Avatar
bzdbbb bzdbbb is offline
X-Fi2 Development Moderator
 
Join Date: Dec 2009
Location: Gloucestershire, UK
Posts: 94
Default

Quote:
The good thing is I'm getting no input lag from the touch.move() event which seems to be the bottleneck for everyone(including pong).
Pong doesn't use touch.move(), when in the game loop it just constantly touch.pos()'s.. Maybe putting some kind of limiter on it would help, i'll have a try tonight. (that GMT night :P)
Reply With Quote

  #36  
Old 01-15-2010, 01:09 PM
ThievingSix ThievingSix is offline
Member
 
Join Date: Aug 2008
Posts: 218
Default

Quote:
Originally Posted by bzdbbb View Post
Pong doesn't use touch.move(), when in the game loop it just constantly touch.pos()'s.. Maybe putting some kind of limiter on it would help, i'll have a try tonight. (that GMT night :P)
touch.move(), group of touch.pos(): Same thing. I'm just saying that sleeps and waits are what are holding back our heavy drawing apps.
Reply With Quote

  #37  
Old 01-15-2010, 01:56 PM
Jan_DK's Avatar
Jan_DK Jan_DK is offline
Junior Member
 
Join Date: Mar 2009
Location: Denmark
Posts: 88
Default

Quote:
Originally Posted by bzdbbb View Post
Pong doesn't use touch.move(), when in the game loop it just constantly touch.pos()'s.. Maybe putting some kind of limiter on it would help, i'll have a try tonight. (that GMT night :P)
I think you are on to something, for it's like the movement data buffer
gets overloaded.



Jan_DK
Reply With Quote

  #38  
Old 01-15-2010, 01:58 PM
ThievingSix ThievingSix is offline
Member
 
Join Date: Aug 2008
Posts: 218
Default

I remember the calculator application that you found did a control.read(1) which confused me. Maybe there are parameters that we don't know about that, for example, let us get the most recent addition to the touch queue instead of the oldest.
Reply With Quote

  #39  
Old 01-15-2010, 02:25 PM
Jan_DK's Avatar
Jan_DK Jan_DK is offline
Junior Member
 
Join Date: Mar 2009
Location: Denmark
Posts: 88
Default

Quote:
Originally Posted by ThievingSix View Post
I remember the calculator application that you found did a control.read(1) which confused me. Maybe there are parameters that we don't know about that, for example, let us get the most recent addition to the touch queue instead of the oldest.
I tried playing around with control.read(1) for a short time
it gave me the impression that it acted as a kind of A=GETKEY in basic,
the program halted until touch input, but only for a time like 10 sec.
but then suddenly it did not do anything, so i left it.

I've just tried to limit the touch.pos and control.read and it only makes it worse.
It now only reads the touch input every fifth run, but if you generate a lot
of input(holding the finger on the screen all the time),
then the buffer will then also only get empty, or the queue is moving forward
every fifth run.



pong function game loop line 280
Code:
local count   = 0;

count=count+1;
        if count==5 then
        touch_x, touch_y = touch.pos();
        count=0;
            if control.read() == 1 then
                if (control.isButton() == 1) then
                    if (button.home() == 1) and (button.click() == 1) then
                        room[2] = 0;
                    end;
                end;
            end;
        end;
Jan_DK

Last edited by Jan_DK; 01-15-2010 at 02:37 PM.
Reply With Quote

  #40  
Old 01-15-2010, 02:34 PM
ThievingSix ThievingSix is offline
Member
 
Join Date: Aug 2008
Posts: 218
Default

Quote:
Originally Posted by Jan_DK View Post
I tried playing around with control.read(1) for a short time
it gave me the impression that it acted as a kind of A=GETKEY in basic,
the program halted until touch input, but only for a time like 10 sec.
but then suddenly it did not do anything, so i left it.
HA, stupid me!

Programs can use no sleep or wait if they use control.read(1) instead of control.read().
Reply With Quote

Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump



All times are GMT -5. The time now is 04:46 AM.