|
Post by aurel on Jan 19, 2022 13:10:54 GMT -6
here is how look in RCB
|
|
|
Post by johnno56 on Jan 19, 2022 13:21:33 GMT -6
Well done! A filled rectangle... Certainly better than all the digits being drawn on top of each other... lol There must be a better way of doing this. I too have struggled with that problem in the past... Your solution is simple but effective... Cool. Here is a little RC quirk... In this application, the array t$[], is set to a maximum of 1024... That 'includes' zero. 1024 elements from 0 to 1023. If you want to set a 'size' variable eg: size = 1024... the For...Next loop will be For i = 0 to size - 1 etc... But, in your application, 1 to 1023 works fine as well... If you are interested in RC's text drawing... rcbasic.online/doc/rcbasic_manual.html then click 'Drawing Text'. The examples are somewhat incomplete or missing... but it will give you some ideas...
|
|
|
Post by aurel on Jan 19, 2022 13:41:38 GMT -6
thanks RC is not that complex but need some time to get what is what then i can test it in microA.. it is just primitive graphics of course RCB is far more better and advanced than mine experimental basic. all fine
|
|
|
Post by n00b on Jan 19, 2022 15:11:50 GMT -6
I know that is not same and use much more time number to string conversion then assign to array element but I testing similar thing with conversion to string ..then figured that i dont have str$() function in microA then quickly made it to test how work some mumbo jumbo with string expression parser and seems that work.. ok on RCB on my comp above program take cca 12 seconds on microA take 3 second ,but i dont have array yet (shame on me ) would use probably same even maybe 1 to 3 second more ..maybe uhh benchmarks are hard... aurel The RC version was so slow because you were running it with VSync on. Change line 4 to this: WindowOpen(0, "Fill_Array_by Aurel", WINDOWPOS_CENTERED, WINDOWPOS_CENTERED, 640, 480, WINDOW_VISIBLE, 1)
|
|
|
Post by aurel on Jan 19, 2022 16:36:10 GMT -6
hi @noob
but in last code i already use same :
WindowOpen(0, "Fill_Array_by Aurel", WINDOWPOS_CENTERED, WINDOWPOS_CENTERED, 640, 480, WINDOW_VISIBLE, 1)
so all is fine ...i don't fill array in microA just using str$
|
|
|
Post by n00b on Jan 19, 2022 17:12:09 GMT -6
hi @noob but in last code i already use same : WindowOpen(0, "Fill_Array_by Aurel", WINDOWPOS_CENTERED, WINDOWPOS_CENTERED, 640, 480, WINDOW_VISIBLE, 1) so all is fine ...i don't fill array in microA just using str$ Sorry, I meant to say change it to this: WindowOpen(0, "Fill_Array_by Aurel", WINDOWPOS_CENTERED, WINDOWPOS_CENTERED, 640, 480, WINDOW_VISIBLE, 0) The last argument should be 0.
|
|
|
Post by aurel on Jan 20, 2022 2:06:51 GMT -6
yes @noob it is faster aroud 3 second take on this way.good!
|
|