Questions tagged [line-drawing]
55 questions
0
votes
1 answer
SVG path drawing animation - line drawing with anime.js, how to stop lines from overlapping
I have the following SVG line drawing using anime.js but for some reason the lines seem to overlap during the animation. I have played around with all the settings including removing the loop, changing the direction etc etc but nothing I change…

LeeTee
- 6,401
- 16
- 79
- 139
0
votes
1 answer
How to correct my negative index in the line.new() ? Pinescript
//I'm having problems with the line.new function. I want a line from close to close between 0830-1630, so probably a diagonal...
_zoneSession = input(title = "Session", type = input.session, defval = "0830-1630:1234567")
_zoneInitialBalanceStop …

Raphaël Vigneault
- 11
- 3
0
votes
1 answer
How can I draw a ine between the first and last point dynamically
I'm making a program where a user can draw a room roughly, than he/she needs to put in the lengths from the walls and then my program makes a detailed drawing of it in a new canvas. I get all the lines working but only the last line between the…

UveGotToFailToSucceed
- 53
- 1
- 6
0
votes
0 answers
Fast 2D line drawing
Few months ago I coded in C++ a (high quality) zen photon ripoff, and I want to start over from the scratch. Was quite fun and I managed to get some nice results. The biggest performance bottleneck was the line drawing part, since I need to draw…
0
votes
0 answers
How to fill the gaps in an image after thinning?
How can I fill the gaps that occurred as a result of thinning? The first image is the image before thinning, the second one is the image after thinning and the third one is an example of the pixels that I need to connect. I'm using MATLAB R2013a.
I…

H. Nagaty
- 13
- 1
- 5
0
votes
0 answers
Is there an efficient Xiaolin Wu's line function with SDL (or an add on)?
I made a program in C++ with SDL2 which draws a curve from a list of points by linking them with lines. I'm using the SDL_RenderDrawLine function, which is based on Bresenham's algorithm, I assume.
Then I made an other function based on Xiaolin Wu's…

MacGlory
- 11
- 1
0
votes
2 answers
Animated glowing SVG line drawing not working across browsers
I'm trying to create an animation that uses SVG filters and the stroke-dasharray approach to create a progressively drawn "glowing" line effect. After quite a bit of research I was able to put together something that sort of works:
JSFiddle (the SVG…

Rich
- 3,156
- 3
- 19
- 29
0
votes
0 answers
how to draw a horizontal/vertical line and still have a rectangle for bounds purposes ins C#
I am using this code to create a rectangle:
public static Rectangle RectangleFromPoints(Point a, Point b)
{
return new Rectangle(Math.Min(a.X, b.X),
Math.Min(a.Y, b.Y),
…

Ludos The Brave
- 9
- 2
0
votes
1 answer
How to draw a line in SpriteKit efficiently
In my SpriteKit scene, user should be able to draw line with his/her finger. I have a working solution, if the line is long, FPS gets down to 4-6 and the line starts to get polygonal, as the image below:
To draw myline (SKShapeNode*), I collect…

ddb
- 2,423
- 7
- 28
- 38
0
votes
1 answer
Flash AS3 drawline displays text
I'm currently working on a nomograph and I was able to create 2 sliders connected with a line, but is there a way to get the line to read the middle numbers kind of like in the example below.
I'd need the line to display multiple numbers of the…

Shawn C. Machie
- 5
- 6
0
votes
1 answer
Drawing a set of parallel lines at various angles for finding the mean intercept length
I am trying to write a code to find the Mean Intercept Length tensor. The mean intercept length tensor will help me find the orientation of a given image. For that I need to create a set of parallel sample lines equidistant from each other filling…

JOY
- 3
- 1
0
votes
1 answer
ANSI commands for drawing boxes in terminal
I am trying to draw a box on the screen that looks like this:
┌───┐
└───┘
I found ANSI commands to move the cursor here:
http://www.tldp.org/HOWTO/Bash-Prompt-HOWTO/x361.html
My code looks like this:
int main()
{
int boxsize = 5;
…

lo tolmencre
- 3,804
- 3
- 30
- 60
0
votes
1 answer
Rotate line around center
I have to use a propriertary graphics-engine for drawing a line. I can rotate the whole drawing by its origin point (P1). What I want, is to rotate it around its center point(M). So basically that it looks like L_correct instead of L_wrong.
I think,…

Tofferino
- 23
- 1
- 2
- 8
0
votes
3 answers
Point / Line Detection Based on a Set of Consecutive / Semi-Consecutive Points
I am trying to write some point / line detection software based on what a user is drawing on a canvas (I have been doing this all via the web and html 5 canvas). When a user performs a MouseDown event we create an array that will hold all of the…

Greg Valainis
- 190
- 1
- 8
0
votes
0 answers
Java FX dragging and deleting lines
Today I need your help with JavaFX 2. I have an exercise to draw lines using mouse, then make them draggable with pressed CTRL and leftMouse press and drag, and delete them using ctrl+clicked rightMouse. I understand an algorithm, but don't know…

vladys.bo
- 730
- 2
- 11
- 34