Page 1 of 2
Vanishing Point Tool
Posted: 27 Jun 2012, 06:42
by v.veidt
I've made this brush to serve as a vanishing point tool for creating perspective grids. It's a fairly simple set of radiating lines, which is scalable and can be modified by the Tint brushes in the Sketch Panel. I hope you find it useful.
This file was made in TVP 9.5 Standard if it matters.
Re: Vanishing Point Tool
Posted: 27 Jun 2012, 07:53
by Elodie
Thank you for sharing
Re: Vanishing Point Tool
Posted: 27 Jun 2012, 12:00
by Animark
Great! Thumbs up!
... and thanks a lot
Re: Vanishing Point Tool
Posted: 12 Jul 2012, 21:15
by lemec
This is a rather heavily modified version of
KylerK's vanishing point tool.
This version automatically switches you to the propelling pencil and restores your brush afterwards.
It makes use of the tv_undoOpenStack and tv_undoCloseStack commands to avoid clobbering your undo buffer
It locks/unlocks the display during operation for faster results.
It also uses tv_zLine to fade the opacity at the center point to eliminate the "fuzzy navel" artifact at the vanishing point
- Using the first script
Code: Select all
Param Circle
Parse result command Cx Cy r button
tv_getActiveTool
oldTool = Result
if r>800
t=800
Else
t=r
End
tv_projectInfo
parse Result name width height extra
maxLen = sqr(width*width + height*height)
tv_propelling mode "color" power 100 opacity 100 dry 0 aaliasing 1 gradient 0 cpower "10;2 0 1 0 0 1 1 "
tv_undoOpenStack
tv_lockDisplay
FOR i = 1 TO t
angle = i * (360 / t)
x1=COS(angle) * maxLen
y1=SIN(angle) * maxLen
tv_ZLine Cx Cy x1+Cx y1+Cy button 0 255
END
tv_UnLockDisplay
tv_cmd oldTool
tv_undoCloseStack "Perspective Guide"
This one is a little different in that it randomizes the angle and the distance to the center point. It doesn't affect the current tool, so it's useful for various zooming effects.
- Using the second script
Code: Select all
Param Circle
Parse result command Cx Cy r button
tv_projectInfo
parse Result name width height extra
maxLen = sqr(width*width + height*height)
r = 800 * (r / (maxLen / 3))
if r>800
t=800
Else
t=r
End
tv_undoopenstack
tv_LockDisplay
FOR i = 1 TO t
r1 = rnd(maxLen / 2)
o2 = 255 * (1 - (r1 / (maxLen / 2)))
angle = rnd(3600)
x2=COS(angle/10)
y2=SIN(angle/10)
x1=x2 * maxLen
y1=y2 * maxLen
x2 = x2 * r1
y2 = y2 * r1
tv_ZLine x2+Cx y2+Cy x1+Cx y1+Cy button 0 o2
END
tv_UnLockDisplay
tv_undoclosestack "Radial Burst"
Re: Vanishing Point Tool
Posted: 12 Jul 2012, 21:32
by lemec
- With the right settings...
- vPForestTool.png (23.48 KiB) Viewed 5826 times
Re: Vanishing Point Tool
Posted: 13 Jul 2012, 06:55
by Elodie
Wow, very nice
Re: Vanishing Point Tool
Posted: 13 Jul 2012, 07:39
by v.veidt
Wow, thanks for all the work, especially with the "fuzzy navel" issue. I suppose I should really learn to script for TVP.
Not to seem belligerently ignorant, but how does one implement these wonderful scripts?
Re: Vanishing Point Tool
Posted: 13 Jul 2012, 08:44
by lemec
1: create a new custom panel action (right click an empty spot on an EDITABLE custom panel and choose Add Action)
2: edit the new action (right click it)
3: Choose Embedded Script
4: copy/paste the script of your choice into the script window that comes up.
Re: Vanishing Point Tool
Posted: 13 Jul 2012, 22:09
by v.veidt
I can't seem to get either of these scripts to work. The Param Circle command is definitely working and I don't get an error message, but there is no result when I use the action. Is there any reason this would not work on Mac OS X?
Update: It works flawlessly on Windows. Now I'm extra glad I switched over. Thanks.
Re: Vanishing Point Tool
Posted: 24 Jul 2012, 07:34
by kariP
They both seem to work on my mac, very nice, especially the perspective tool!
I adjusted the opacity of the endpoint from 0 to 3. Now it creates a small dot into the horizon, which is a bit clearer for me. And with low amount of lines, no funny stuff on the navel area either. A Big thank you for the script!
Re: Vanishing Point Tool
Posted: 24 Jul 2012, 07:56
by lemec
Hm. Maybe I should make a version that will set the vanishing point to the intersection of two non-parallel lines. Might be useful for getting perspective guides for imagery that has an existing vanishing point.
Re: Vanishing Point Tool
Posted: 24 Jul 2012, 08:05
by Fabrice
hey Mark and Vincent Veidt, excellent job, as usual
Re: Vanishing Point Tool
Posted: 08 Aug 2012, 15:09
by Peter Wassink
lemec wrote:Hm. Maybe I should make a version that will set the vanishing point to the intersection of two non-parallel lines. Might be useful for getting perspective guides for imagery that has an existing vanishing point.
you mean a version with an input of four points that would create a grid to match an existing image?
cool idea!
Re: Vanishing Point Tool
Posted: 08 Aug 2012, 16:26
by slowtiger
+1. That's something so fundamental, yet I haven't seen it in any graphics program yet: let the user create a rectangle or tetragon, and the script would create a grid of that. Adjust the original tetragon, and the grid changes with it.
- grid.png (30.34 KiB) Viewed 5691 times
Re: Vanishing Point Tool
Posted: 09 Aug 2012, 12:32
by Fabrice
Maybe it can help :
The vanishing points are usable in the warp tool.
So if you draw a grid on the screen, you can use the warp tool to put it in perspective, using the vanishing points of the warp tool.
nb : This kind of grid is in the ToDo list for a future 10.x version. with the complete renewal of grid, guides, etc ... (old code ...)