Discuss Scratch
- Discussion Forums
- » Help with Scripts
- » How to make a color at x: y: block??
- sharngi
- Scratcher
95 posts
How to make a color at x: y: block??
define Color at x:(x position :: custom-arg) y:(y position :: custom-arg)Hi im wanting to define this block for a pen webcam but i seem to not find anything
set [color v] to (color :: custom-arg)
If any of you guys know how to that would be awesome and i will give credits to you thanks!!
CCCCCHHHHHHHHHEEEEEEEEECCCCCCCCCKKKKKKKKKK OOOOOUUUUUTTTTTTTTT
MMMMMMMMMMMMMMMMMMYYYYYYYYY PPPPPRRRRROOOOFFFIIILLLEEEE
MMMMMMMMMMMMMMMMMMYYYYYYYYY PPPPPRRRRROOOOOFFFIIILLLLEE
and leave a comment if you did have a good day!
- footsocktoe
- Scratcher
1000+ posts
How to make a color at x: y: block??
define Color at x:(x position :: custom-arg) y:(y position :: custom-arg)Hi im wanting to define this block for a pen webcam but i seem to not find anything
set [color v] to (color :: custom-arg)
If any of you guys know how to that would be awesome and i will give credits to you thanks!!
Need more info. What is “color”?
SHOOT THE SPACE MONSTERS! ….. A game everyone can play! Bright colors, bonky sounds!
THE 12 BALLS OF CRAZY AL ……. New scrolling adventure game!
- gtoal
- Scratcher
1000+ posts
How to make a color at x: y: block??
Reading a pixel off the screen is unbelievably slow - I hope the camera is pointing at a still image. It will take minutes to scan.
- sharngi
- Scratcher
95 posts
How to make a color at x: y: block??
its the color of the define block since you cant define reporter blocksdefine Color at x:(x position :: custom-arg) y:(y position :: custom-arg)Hi im wanting to define this block for a pen webcam but i seem to not find anything
set [color v] to (color :: custom-arg)
If any of you guys know how to that would be awesome and i will give credits to you thanks!!
Need more info. What is “color”?
CCCCCHHHHHHHHHEEEEEEEEECCCCCCCCCKKKKKKKKKK OOOOOUUUUUTTTTTTTTT
MMMMMMMMMMMMMMMMMMYYYYYYYYY PPPPPRRRRROOOOFFFIIILLLEEEE
MMMMMMMMMMMMMMMMMMYYYYYYYYY PPPPPRRRRROOOOOFFFIIILLLLEE
and leave a comment if you did have a good day!
- footsocktoe
- Scratcher
1000+ posts
How to make a color at x: y: block??
its the color of the define block since you cant define reporter blocksdefine Color at x:(x position :: custom-arg) y:(y position :: custom-arg)Hi im wanting to define this block for a pen webcam but i seem to not find anything
set [color v] to (color :: custom-arg)
If any of you guys know how to that would be awesome and i will give credits to you thanks!!
Need more info. What is “color”?
The color of the define block is purple.
What are you trying to do? What are you trying to accomplish? Are you trying to scan something like gtoal suggested?
SHOOT THE SPACE MONSTERS! ….. A game everyone can play! Bright colors, bonky sounds!
THE 12 BALLS OF CRAZY AL ……. New scrolling adventure game!
- sharngi
- Scratcher
95 posts
How to make a color at x: y: block??
Yes im making a pen webcamits the color of the define block since you cant define reporter blocksdefine Color at x:(x position :: custom-arg) y:(y position :: custom-arg)Hi im wanting to define this block for a pen webcam but i seem to not find anything
set [color v] to (color :: custom-arg)
If any of you guys know how to that would be awesome and i will give credits to you thanks!!
Need more info. What is “color”?
The color of the define block is purple.
What are you trying to do? What are you trying to accomplish? Are you trying to scan something like gtoal suggested?
CCCCCHHHHHHHHHEEEEEEEEECCCCCCCCCKKKKKKKKKK OOOOOUUUUUTTTTTTTTT
MMMMMMMMMMMMMMMMMMYYYYYYYYY PPPPPRRRRROOOOFFFIIILLLEEEE
MMMMMMMMMMMMMMMMMMYYYYYYYYY PPPPPRRRRROOOOOFFFIIILLLLEE
and leave a comment if you did have a good day!
- JEMA2311
- Scratcher
65 posts
How to make a color at x: y: block??
1- I think nobody is understanding quite well your idea. Remember, for now or in the future, if you need help with something, try to be as clear and specific as you can, so the community can help you. Yes im making a pen webcam
2- I believe I understood, let's give it a try… what you want is to detect what's the color in a certain (X, Y) position… Am I right?
Last edited by JEMA2311 (Aug. 8, 2017 04:26:03)
Keep Doing What You Like
………..JEMA2311………..
Check out my Clone Scrolling Method
and also my custom block “Move (X) (S/N) steps”,
which simplifies the character's motion
- gtoal
- Scratcher
1000+ posts
How to make a color at x: y: block??
she wants to extract an image from the camera by reading pixels off the screen.1- I think nobody is understanding quite well your idea. Remember, for now or in the future, if you need help with something, try to be as clear and specific as you can, so the community can help you. Yes im making a pen webcam
2- I believe I understood, let's give it a try… what you want is to detect what's the color in a certain (X, Y) position… Am I right?
i think there may be some examples of how to do that in the “graphics101” studio.
- footsocktoe
- Scratcher
1000+ posts
How to make a color at x: y: block??
Yes im making a pen webcamits the color of the define block since you cant define reporter blocksdefine Color at x:(x position :: custom-arg) y:(y position :: custom-arg)Hi im wanting to define this block for a pen webcam but i seem to not find anything
set [color v] to (color :: custom-arg)
If any of you guys know how to that would be awesome and i will give credits to you thanks!!
Need more info. What is “color”?
The color of the define block is purple.
What are you trying to do? What are you trying to accomplish? Are you trying to scan something like gtoal suggested?
Then you should know this about Scratch and the colors of pixels…
In Scratch, you can set up a reference color and then detect whether a pixel is that color or not. That's all you can do.
Since there are over 16 million colors in the RGB color space, detecting which one a pixel is would require 16 million detectors. Obviously impossible.
BUT, if you limit the number of colors you detect to fewer, then it becomes more possible.
HOWEVER, you should also know this. The color detect block is slow, so you could not scan a moving webcam image. The webcam would have to be focused on something that does not move and the scanning would take anywhere from several minutes to several hours depending on how many colors you used.
If you have a dream of capturing moving webcam images, then forget it. That one is impossible to do with Scratch.
SHOOT THE SPACE MONSTERS! ….. A game everyone can play! Bright colors, bonky sounds!
THE 12 BALLS OF CRAZY AL ……. New scrolling adventure game!
- Discussion Forums
- » Help with Scripts
- » How to make a color at x: y: block??