Download the free trial version
Basic4android Video
Features
Tutorials and manuals
Showcase
Screenshots

Go Back   Android Development Forum - Basic4android > Basic4ppc (Windows Mobile) > Share Your Creations
Documentation Wiki Register Members List B4P Search Today's Posts Mark Forums Read

Share Your Creations Show your developed application to Basic4ppc community. Please include source code if possible.

Rolling coins

Reply
 
LinkBack Thread Tools Display Modes
  #11 (permalink)  
Old 10-02-2008, 11:40 AM
Cableguy's Avatar
Basic4ppc Expert
 
Join Date: Apr 2007
Location: N 41º11'30.30" W 8º39'46.60"
Posts: 2,344
Awards Showcase
Forum Contributer 
Total Awards: 1
Default

Quote:
Originally Posted by klaus View Post
- by default when changing the small circle, put the drawing radius at the same value.
Please DON'T!!!
Very nice effects can be achieved this way as the smaller coin rolls faster, than the drawing radius...
if you Grow the coin to the radius, you will see that the effect is NOT the same...
__________________
Paulo Gomes - Porto, Portugal - Living/Working in France
Mobile Device: Samsung Galaxy S, Android 2.3.4 CUstom ROM
Laptop: Toshiba NB100-130 (running on Win7Ultimate)

My Posts helped you? Consider Buying me a Porto Glass!
Reply With Quote
  #12 (permalink)  
Old 10-02-2008, 12:11 PM
Junior Member
 
Join Date: Jul 2008
Posts: 37
Default

Ok - thakns all for the usefull sugestions. I've already put in the pole length default, and the stop loop on closure - I wondered why my computer was starting to struggle, task manager showed all those little rollers eating up the cpu.

Mr Gee - I'm not sure what you mean by different sizes ??.

Also by multilpe rings, do you mean multiple moving circles rolling inside or outside the fixed circle, or one inside and one outside or a combination.

Also I have to be careful of pixel-estate since I want to allow the largest graph possible.

PS - Kkaus - I promise to put in some effort with the icon editor to make a nicer icon for this. Still - if anyone has a premade nice one I could borrow ???

Cableguy - I think klas intends that when you change to size of the movable circle you also reset the pole length equal to the new radius. You can still change the pole length again to be different to the new movable radius.

Certainly I have found myself having to make identical changes to the pole after altering the movbable circle more often than I've changed the movable radius and wanted to leave the pole length the same.
Reply With Quote
  #13 (permalink)  
Old 10-02-2008, 03:04 PM
klaus's Avatar
Basic4ppc Expert
 
Join Date: Oct 2007
Location: Fully, Switzerland
Posts: 4,463
Awards Showcase
Forum Contributer Beta Tester Competition Winner 
Total Awards: 3
Default

Have a look at specci48's link to wikipedia and you will understand Mr_Gee's suggestions.
- You can make a first draw with a certain configuration of the 3 parameters, press Stop
- Begin an other drawing, with an other color and an other configuration, without clearing the screen to superpose it to the first one.
- And a 3rd, 4th and so on.

In this case it would also be interesting to be able to choose the beginning point.

Best regards.
__________________
Klaus
Switzerland

Beginner's Guide / User's Guide
Reply With Quote
  #14 (permalink)  
Old 10-03-2008, 01:33 PM
Junior Member
 
Join Date: Jul 2008
Posts: 37
Default

Here the next version with a couple of tiny changes.

Bug fixes - form will now close properly

Added Features:

Exit button added

Changing parameters will not clear previous graph (use clear button to do this).

Lift/draw button added - if you want to make multiple changes to the parameters before starting a new graph then lift the pen, then hit draw to start drawing again when the parameters are all correct.

When resizing the movable radius the drawing radius will default to the new size (this drawing radius can be altered independently afterwards if required)

NB this default will be implemented optionally soon in an ini file.

1)TODO list

Option initialisation:
a) - colours
b)- drawing radius default
c) - start parameters

2) Colours:
a) pen
b) background
c) circles/pole ??? ( I think these should stay ghosted)


3) Better graphics - try to use setpixel to get a finer, more accurate line.

4) Graph movement
a) allow centre of drawing to move (Easy)
b) allow "slippy map" functionality and gesturing (Hard)

--------------------------------------------------

BTW This program started since discussing with my father about the envelope
of the sliding ladder situation (see ladder.sbp) we found that the astroid could also be produced by rolling circles.

PS - excuse the primitave nature of my coding - I may get better at it but after 30 years the chances are not all that good

Nick
Attached Files
File Type: sbp rolling.sbp (3.7 KB, 24 views)
File Type: sbp ladder.sbp (3.7 KB, 29 views)
Reply With Quote
  #15 (permalink)  
Old 10-03-2008, 03:07 PM
Junior Member
 
Join Date: Jul 2008
Posts: 37
Default

PPS
TODO List

Screen snapshot
with and/or without paramater areas.
Reply With Quote
  #16 (permalink)  
Old 10-04-2008, 06:26 AM
Junior Member
 
Join Date: Jul 2008
Posts: 37
Default

One more version - before colours appear

If the drawing is too slow on your device even after hitting + a few times then you can choose the otions form (while the pen is lifted) and drop the quality down from the default of 100 (to maybe 50 or so).

On this form you can also disable the "pole sync" which defaults the drawing radius to to movable radius whenever the movable radius is altered.

Colours will be next but will take some time as I want to make it simple yet flexable.

Nick
Attached Files
File Type: sbp rolling.sbp (4.4 KB, 24 views)
Reply With Quote
  #17 (permalink)  
Old 10-05-2008, 01:59 PM
Junior Member
 
Join Date: Jul 2008
Posts: 37
Default

Here's a colour version (for desktop only).

Beware - changing background colour wipes out the drawing.

I've had to move the fixed circle to the forelayer so that it didn't intefere with the drawing bit I can't stop it flickering (any advice appreciated).

Next I'll do the boring stuff such as save/load/snap etc

I intend to allow save/store of a graph (A graph is the set of parameters used while drawing (i.e with pen down) since the last clear command)

E.G
cBack,I,10,40,10,cPen1:O,10,40,10,cPen2:O,10,40,30 ,cPen2

The graph will be saved, on closing to the savefile as "lastgraph". You can also save it to "favourite" or to a table of savedgraphs.

On startup, lastgraph will load and start drawing. You can reload and redraw any user-named graph from the savedlist or the favourite graph.

I'l also enable a snapshot of the screen, with or without the controls displayed, to disk or printer.

I'll define a file for the user preferences to be created on first execution and used thereafter to save session status etc.
Attached Files
File Type: sbp rollingdesk.sbp (5.4 KB, 23 views)
Reply With Quote
  #18 (permalink)  
Old 10-09-2008, 12:53 PM
Junior Member
 
Join Date: Jul 2008
Posts: 37
Default

While searching for bugs in my program, I came across this one.
It looks a bit like a trilobite. Does anyone know its name.

Its number is
I,10,30,10 ----- deltoid
I,10,40,10 - ----astroid
.
.
.
I,10.90,10
Attached Images
File Type: jpg cybug.JPG (19.1 KB, 24 views)
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are On


All times are GMT. The time now is 12:05 PM.


Powered by vBulletin® Version 3.6.12
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.3.0