This is a read-only archive of the old Scratch 1.x Forums.
Try searching the current Scratch discussion forums.

#26 2012-11-18 20:08:54

TorbyFork234
Scratcher
Registered: 2012-03-01
Posts: 1000+

Re: An Idea That Will Blow Your Mind

RoboNeo9 wrote:

TorbyFork234 wrote:

RoboNeo9 wrote:


Not quite ULTRA slow, just slow.

yes, ultra slow.

For every pixel, it will have to do about 100 checks (if you put them in if elses, it'll go quicker, I'm averaging to 100). So 1 point of data is 100 Scratch calculations, so far. Then, it'll have to check if it's the last point of data. So it would have to check every pixel around it, which is 8 more pixels. 820 calculations (for the initial ifs I add 20) per point. It would then have to do this for about 25x25 pixels, which means 625 pixels.
So, to just map out the data, you would have to have about 512,500 scratch calculations. Which is A LOT!!! and makes it ultra slow.
For the actual angles and edges, I don't know the complex math around it, but for the entire object, I'm going to add in 5000 (because of the complex math, it's not just 1+1, it's more calculations.).
to get one object, and to find the angles/edges, it would take you 517,500 scratch calculations. And if you make a simple "TURBO" speed calculation detector (if you want I can make it for you), you can see how long it takes for it to do 1+1 517,500 times.

I see your point now. It won't quite take 100 calculations per pixel because scratch already "rounds" the colors to a more basic color so really close colors are counted as the same.

No, according to pen colors (pen colors only, not even pen shades mixed in with pen colors), there's 200 different colors.

Offline

 

#27 2012-11-20 08:05:03

RoboNeo9
Scratcher
Registered: 2012-05-09
Posts: 100+

Re: An Idea That Will Blow Your Mind

TorbyFork234 wrote:

RoboNeo9 wrote:

TorbyFork234 wrote:


yes, ultra slow.

For every pixel, it will have to do about 100 checks (if you put them in if elses, it'll go quicker, I'm averaging to 100). So 1 point of data is 100 Scratch calculations, so far. Then, it'll have to check if it's the last point of data. So it would have to check every pixel around it, which is 8 more pixels. 820 calculations (for the initial ifs I add 20) per point. It would then have to do this for about 25x25 pixels, which means 625 pixels.
So, to just map out the data, you would have to have about 512,500 scratch calculations. Which is A LOT!!! and makes it ultra slow.
For the actual angles and edges, I don't know the complex math around it, but for the entire object, I'm going to add in 5000 (because of the complex math, it's not just 1+1, it's more calculations.).
to get one object, and to find the angles/edges, it would take you 517,500 scratch calculations. And if you make a simple "TURBO" speed calculation detector (if you want I can make it for you), you can see how long it takes for it to do 1+1 517,500 times.

I see your point now. It won't quite take 100 calculations per pixel because scratch already "rounds" the colors to a more basic color so really close colors are counted as the same.

No, according to pen colors (pen colors only, not even pen shades mixed in with pen colors), there's 200 different colors.

That's an outrageous amount!

Offline

 

#28 2012-11-20 16:54:36

TheSupremeOverLord
Scratcher
Registered: 2012-09-29
Posts: 100+

Re: An Idea That Will Blow Your Mind

I was thinking of doing the same thing!


http://i1154.photobucket.com/albums/p522/lizzyhipo/MINIPIG.jpg

Offline

 

#29 2012-11-20 17:33:28

RoboNeo9
Scratcher
Registered: 2012-05-09
Posts: 100+

Re: An Idea That Will Blow Your Mind

RoboNeo9 wrote:

TorbyFork234 wrote:

RoboNeo9 wrote:


I see your point now. It won't quite take 100 calculations per pixel because scratch already "rounds" the colors to a more basic color so really close colors are counted as the same.

No, according to pen colors (pen colors only, not even pen shades mixed in with pen colors), there's 200 different colors.

That's an outrageous amount!

I guess I could use the "or" Boolean to make it a bit faster

Offline

 

#30 2012-11-20 19:12:20

TorbyFork234
Scratcher
Registered: 2012-03-01
Posts: 1000+

Re: An Idea That Will Blow Your Mind

RoboNeo9 wrote:

RoboNeo9 wrote:

TorbyFork234 wrote:


No, according to pen colors (pen colors only, not even pen shades mixed in with pen colors), there's 200 different colors.

That's an outrageous amount!

I guess I could use the "or" Boolean to make it a bit faster

if <<touching color [#000000]?> or <touching color [#FFFFFF]?>>
add [What are you going to add?] to [object map v]
end
What are you going to add into the textbox.
And besides, it's not going to leave out the time, since it still has to check those. In fact, the only thing it might do is increase the time, because what would happen if the color is the second one in the or? you just added another calculation.

That's an outrageous amount!

No, it's not. A lot of monitors can support 2 million colors, and most programming languages allow hex code, which I think is 1024 colors, although I could be mistaken, although in most programming languages, once you get the camera down, recording it is not that hard (from what I've seen in javascript).

Offline

 

#31 2012-11-21 18:59:04

RoboNeo9
Scratcher
Registered: 2012-05-09
Posts: 100+

Re: An Idea That Will Blow Your Mind

if <<touching color [#000000]?> or <touching color [#00000F]?>>
add [Black] to [object map v]
end
I would do that

Offline

 

#32 2012-11-21 19:00:42

RoboNeo9
Scratcher
Registered: 2012-05-09
Posts: 100+

Re: An Idea That Will Blow Your Mind

RoboNeo9 wrote:

when gf clicked
if <<touching color [#000000]?> or <touching color [#00000F]?>>
add [Black] to [object map v]
end
I would do that

But the colors would be just a tiny bit different

Offline

 

#33 2012-11-21 23:06:07

RoboNeo9
Scratcher
Registered: 2012-05-09
Posts: 100+

Re: An Idea That Will Blow Your Mind

I figured out how to scan it really fast! it will have more than one scanner!

Offline

 

#34 2012-11-22 00:16:09

TorbyFork234
Scratcher
Registered: 2012-03-01
Posts: 1000+

Re: An Idea That Will Blow Your Mind

RoboNeo9 wrote:

RoboNeo9 wrote:

when gf clicked
if <<touching color [#000000]?> or <touching color [#00000F]?>>
add [Black] to [object map v]
end
I would do that

But the colors would be just a tiny bit different

Ok, but black could account for a lot of colors.

And that wouldn't reduce time, that would increase time, but reduce length (not width) of the script.

RoboNeo9 wrote:

I figured out how to scan it really fast! it will have more than one scanner!

That could work for 2.0 cloning, but how would you make them interact with each other. Because each scanner would have to know what happened in the line before it to know where the object starts/ends.
You do know how complex this is going to be, right?

Offline

 

#35 2012-11-22 09:08:12

Firedrake969
Scratcher
Registered: 2011-11-24
Posts: 1000+

Re: An Idea That Will Blow Your Mind

If someone makes that, I'll take it a step farther.
I'll add the coordinates and color number to a cloud list.  Then, other people could request/search pictures, assuming you have a name for the picture, and they get it!


Click the sign.
https://s3.amazonaws.com/eterna/eterna2/logo2.png

Offline

 

#36 2012-11-22 10:21:31

TheSupremeOverLord
Scratcher
Registered: 2012-09-29
Posts: 100+

Re: An Idea That Will Blow Your Mind

It doesn't seem that hard.  As firedrake said, you could create an info base, and add coordinates.  It seems Luke a project quite a few people will do.


http://i1154.photobucket.com/albums/p522/lizzyhipo/MINIPIG.jpg

Offline

 

#37 2012-11-22 10:28:28

RoboNeo9
Scratcher
Registered: 2012-05-09
Posts: 100+

Re: An Idea That Will Blow Your Mind

TorbyFork234 wrote:

RoboNeo9 wrote:

RoboNeo9 wrote:

when gf clicked
if <<touching color [#000000]?> or <touching color [#00000F]?>>
add [Black] to [object map v]
end
I would do that

But the colors would be just a tiny bit different

Ok, but black could account for a lot of colors.

And that wouldn't reduce time, that would increase time, but reduce length (not width) of the script.

RoboNeo9 wrote:

I figured out how to scan it really fast! it will have more than one scanner!

That could work for 2.0 cloning, but how would you make them interact with each other. Because each scanner would have to know what happened in the line before it to know where the object starts/ends.
You do know how complex this is going to be, right?

yeah, i know

Offline

 

#38 2012-11-22 14:07:27

TorbyFork234
Scratcher
Registered: 2012-03-01
Posts: 1000+

Re: An Idea That Will Blow Your Mind

TheSupremeOverLord wrote:

It doesn't seem that hard.  As firedrake said, you could create an info base, and add coordinates.  It seems Luke a project quite a few people will do.

RoboNeo is trying not to sense the picture that shows up, he's trying to sense the picture, then take out objects from the picture, just by scanning it. Like if you're holding a cube up the camera, he's trying to make it so that the computer will recognize the cube, and set up a perimeter around it. From there, yes it's easy to just upload the data to a cloud list, but that's not what's really complicated.

Offline

 

#39 2012-11-22 15:40:25

RoboNeo9
Scratcher
Registered: 2012-05-09
Posts: 100+

Re: An Idea That Will Blow Your Mind

TorbyFork234 wrote:

TheSupremeOverLord wrote:

It doesn't seem that hard.  As firedrake said, you could create an info base, and add coordinates.  It seems Luke a project quite a few people will do.

RoboNeo is trying not to sense the picture that shows up, he's trying to sense the picture, then take out objects from the picture, just by scanning it. Like if you're holding a cube up the camera, he's trying to make it so that the computer will recognize the cube, and set up a perimeter around it. From there, yes it's easy to just upload the data to a cloud list, but that's not what's really complicated.

I have made the part where you make a perimeter around it already in panther

Offline

 

#40 2012-11-22 20:36:18

TorbyFork234
Scratcher
Registered: 2012-03-01
Posts: 1000+

Re: An Idea That Will Blow Your Mind

RoboNeo9 wrote:

TorbyFork234 wrote:

TheSupremeOverLord wrote:

It doesn't seem that hard.  As firedrake said, you could create an info base, and add coordinates.  It seems Luke a project quite a few people will do.

RoboNeo is trying not to sense the picture that shows up, he's trying to sense the picture, then take out objects from the picture, just by scanning it. Like if you're holding a cube up the camera, he's trying to make it so that the computer will recognize the cube, and set up a perimeter around it. From there, yes it's easy to just upload the data to a cloud list, but that's not what's really complicated.

I have made the part where you make a perimeter around it already in panther

Perimeter around the object, or perimeter around the space for it to look for an object? Or is it just a pen square you can adjust the size of, and it gets where to sense from you making that square?

Offline

 

#41 2012-11-22 22:29:28

TheSupremeOverLord
Scratcher
Registered: 2012-09-29
Posts: 100+

Re: An Idea That Will Blow Your Mind

My dad and I are trying to create a project similar to that in processing.


http://i1154.photobucket.com/albums/p522/lizzyhipo/MINIPIG.jpg

Offline

 

#42 2012-11-22 23:25:07

RoboNeo9
Scratcher
Registered: 2012-05-09
Posts: 100+

Re: An Idea That Will Blow Your Mind

TorbyFork234 wrote:

RoboNeo9 wrote:

TorbyFork234 wrote:


RoboNeo is trying not to sense the picture that shows up, he's trying to sense the picture, then take out objects from the picture, just by scanning it. Like if you're holding a cube up the camera, he's trying to make it so that the computer will recognize the cube, and set up a perimeter around it. From there, yes it's easy to just upload the data to a cloud list, but that's not what's really complicated.

I have made the part where you make a perimeter around it already in panther

Perimeter around the object, or perimeter around the space for it to look for an object? Or is it just a pen square you can adjust the size of, and it gets where to sense from you making that square?

perimeter around the object itself

Offline

 

#43 2012-11-23 01:04:20

TorbyFork234
Scratcher
Registered: 2012-03-01
Posts: 1000+

Re: An Idea That Will Blow Your Mind

RoboNeo9 wrote:

TorbyFork234 wrote:

RoboNeo9 wrote:

I have made the part where you make a perimeter around it already in panther

Perimeter around the object, or perimeter around the space for it to look for an object? Or is it just a pen square you can adjust the size of, and it gets where to sense from you making that square?

perimeter around the object itself

So you were able to have it know the edges of an object, from a picture, and set up a perimeter around it?
Wow, nice! How complex of math is it?
Or am I just not understanding what you're trying to do?

Last edited by TorbyFork234 (2012-11-23 01:04:39)

Offline

 

#44 2012-11-23 09:51:01

RoboNeo9
Scratcher
Registered: 2012-05-09
Posts: 100+

Re: An Idea That Will Blow Your Mind

TorbyFork234 wrote:

RoboNeo9 wrote:

TorbyFork234 wrote:


Perimeter around the object, or perimeter around the space for it to look for an object? Or is it just a pen square you can adjust the size of, and it gets where to sense from you making that square?

perimeter around the object itself

So you were able to have it know the edges of an object, from a picture, and set up a perimeter around it?
Wow, nice! How complex of math is it?
Or am I just not understanding what you're trying to do?

umm... you put the perimeter around the object yourself. i do know how to make it do it automatically though. it is actually not that hard to do.

Offline

 

#45 2012-11-23 16:19:49

TorbyFork234
Scratcher
Registered: 2012-03-01
Posts: 1000+

Re: An Idea That Will Blow Your Mind

RoboNeo9 wrote:

TorbyFork234 wrote:

RoboNeo9 wrote:

perimeter around the object itself

So you were able to have it know the edges of an object, from a picture, and set up a perimeter around it?
Wow, nice! How complex of math is it?
Or am I just not understanding what you're trying to do?

umm... you put the perimeter around the object yourself. i do know how to make it do it automatically though. it is actually not that hard to do.

What is the object, from a picture, or a pre-drawn sprite?

Isn't it hard to do? because how will you know which object to set up, how will you know what color it is, what direction it's facing, etc...?

Last edited by TorbyFork234 (2012-11-23 16:20:12)

Offline

 

#46 2012-11-23 16:54:31

RoboNeo9
Scratcher
Registered: 2012-05-09
Posts: 100+

Re: An Idea That Will Blow Your Mind

TorbyFork234 wrote:

RoboNeo9 wrote:

TorbyFork234 wrote:


So you were able to have it know the edges of an object, from a picture, and set up a perimeter around it?
Wow, nice! How complex of math is it?
Or am I just not understanding what you're trying to do?

umm... you put the perimeter around the object yourself. i do know how to make it do it automatically though. it is actually not that hard to do.

What is the object, from a picture, or a pre-drawn sprite?

Isn't it hard to do? because how will you know which object to set up, how will you know what color it is, what direction it's facing, etc...?

an object from a picture taken during the game

Offline

 

#47 2012-11-24 15:15:41

ArloarLoLs
Scratcher
Registered: 2012-08-27
Posts: 71

Re: An Idea That Will Blow Your Mind

Obviously it wont work because the perimeter of the object varies on the distance the object is from the computer screen, the object's rotation also varies the shapr and perimeter of the object. But nice idea.

Offline

 

#48 2012-11-27 05:43:13

aadhirasharma4
New Scratcher
Registered: 2012-11-27
Posts: 3

Re: An Idea That Will Blow Your Mind

Thanks for the links.

Offline

 

#49 2012-12-01 09:04:57

TheCoolDog
Scratcher
Registered: 2011-01-29
Posts: 18

Re: An Idea That Will Blow Your Mind

I'v made a pixel scanner recently:
http://scratch.mit.edu/projects/TheCoolDog/2904044

Last edited by TheCoolDog (2012-12-01 09:07:29)


-TheCoolDog-

Offline

 

#50 2012-12-02 14:38:32

iTweak0r
Scratcher
Registered: 2011-07-30
Posts: 100+

Re: An Idea That Will Blow Your Mind

I think you do not have to wait for 2.0, just have people take a static image with the "add camera costume" button.


Make it in Scratch! because it's cooler when it's made in scratch
http://i.imgur.com/D4iqPHR.png

Offline

 

Board footer