This should be easy, but I'm puzzled....
I have an image, and I want to draw a simple line (with my penColor, penHeight end penWidth) inside the same image object. How do I do this with code?
I dont want to fiddle with the imageData... way too complicated.
Overlaying a graphic with a line on the image and than taking a snapshot could work but I do not like this idea.
I'm looking for something like:
choose line tool
draw a line from 0,0 to 50,50 inside image id 1 <-- I'm missing this command
Any suggestions?
Thanks.
Mario
Draw a line inside of an existing image
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller
Re: Draw a line inside of an existing image
Hi Mario
You can draw with the pencil too like that
Best regards
Jean-Marc
You can draw with the pencil too like that
Code: Select all
on mouseUp
choose pencil tool
drag from 0,0 to 50,50 -- All points must be inside the image
end mouseUp
Jean-Marc
https://alternatic.ch
Re: Draw a line inside of an existing image
Great Jean-Marc!
I completely missed the drag command!
This work perfectly:
Thanks for the help.
Mario
I completely missed the drag command!
This work perfectly:
Code: Select all
on mouseUp
set the penColor to "green"
set the penHeight to 5
set the penWidth to 5
choose line tool
drag from 0,0 to 50,50 -- in an existing image, of course
choose browse tool
end mouseUp
Mario