Jump to content
You must now use your email address to sign in [click for more info] ×

Precise Stroke Adjustment Control (simulate progress)


Recommended Posts

Hi folks,

 

I would like to be able to set much more precisely the gap value of a stroke in Affinity.

There is a trick I'm using quite often (in Sketch) which makes able to finely fake a "progress" of the stroke around a circular shape.

post-7538-0-31095000-1479466093_thumb.png

 

The point is to set the gap of the stroke as the exact diameter of the circle by multiplying π with it's width (for instance, 500*3.14159265359 if your circle is 500px diameter).

This basically means that the gap is now equal to the perimeter of the circle.

By changing the Dash value then, we can precise make the stroke grow around the circle.

PreciseBorderStrokeProgress.mov

 

Sadly in Affinity, gap value goes from 0 to 100, which simply is way less easy to fine tune, to understand, and also prevent choosing whatever stroke width we want etc.

 

I would love to be able to adjust more precisely these values, but ultimately (and I'm sure you Affinity guys knows exactly what I'm going to say ^^), it would be amazing if you could simply provide a new setting for the stroke: "Progress".

With a slider (or precise value input), we could instantly set the progress of a stroke, as well as many other options like how it is etc.

 

Can't wait to hear your thought about it.

 

Cheers.

WebSite.pngTwitter.png500px.pngFlickr.png

Link to comment
Share on other sites

It would be amazing if you could simply provide a new setting for the stroke: "Progress".

With a slider (or precise value input), we could instantly set the progress of a stroke, as well as many other options like how it is etc.

 

Can't wait to hear your thought about it.

 

Cheers.

 

Yep... Maybe the easiest way could be to place an "open" option to pies?

So we could easily work with available handles  :)

 

Also I'd love dimensional input for shapes' parameters.

The white dog, making tools for artists, illustrators and doodlers

Link to comment
Share on other sites

  • 4 weeks later...
  • Staff

Also I'd love dimensional input for shapes' parameters.

 

I have put some thought into this.  There are a number of issues that would need to be addressed.  The main problem is deciding what the values mean.  If you have an object that has some scaling and shear, the idea of 'size' depends on which direction or axis you chose to base things on.  If I take a rectangle and shear it, then I either evaluate the new size based on the new sheared limits, or I try to use the un-sheared original size.  It's not so straight forward - what makes sense to the user.

 

We do allow absolute size values for things like corner size of rounded rectangles.  We do this by eliminating shear from the equation - so the size values are only really true for a shape that has no shear.  We are also able to project the corners in transformed space for this shape.  Something that we can't do with other shapes.

 

Next, if I'm talking about the size of the hole in a donut or pie shape - if the shape is uniform (same width and height), then the size is correct, but if the shape has different height and width, what axis do I assume we use as the basis for calculating the hole size?  You say, "I want a hole of 50 pixels", but the donut is 200 by 300 pixels in real size, so is the hole 1/4 of the width or 1/6 of the height?

SerifLabs team - Affinity Developer
  • Software engineer  -  Photographer  -  Guitarist  -  Philosopher
  • iMac 27" Retina 5K (Late 2015), 4.0GHz i7, AMD Radeon R9 M395
  • MacBook (Early 2015), 1.3GHz Core M, Intel HD 5300
  • iPad Pro 10.5", 256GB
Link to comment
Share on other sites

 

I have put some thought into this.  There are a number of issues that would need to be addressed.  The main problem is deciding what the values mean.  If you have an object that has some scaling and shear, the idea of 'size' depends on which direction or axis you chose to base things on.  If I take a rectangle and shear it, then I either evaluate the new size based on the new sheared limits, or I try to use the un-sheared original size.  It's not so straight forward - what makes sense to the user.

 

We do allow absolute size values for things like corner size of rounded rectangles.  We do this by eliminating shear from the equation - so the size values are only really true for a shape that has no shear.  We are also able to project the corners in transformed space for this shape.  Something that we can't do with other shapes.

 

What you're writing makes perfectly sense.

So for this part I guess there is no solution...

 

Anyway, speaking of donuts...

 

 

 

 

Next, if I'm talking about the size of the hole in a donut or pie shape - if the shape is uniform (same width and height), then the size is correct, but if the shape has different height and width, what axis do I assume we use as the basis for calculating the hole size?  You say, "I want a hole of 50 pixels", but the donut is 200 by 300 pixels in real size, so is the hole 1/4 of the width or 1/6 of the height?

 

I want to dare a solution...

Since you detailed the analytical approach of these shapes, wouldn't make sense to expose the a/b axis of the Ellipse to keep it consistent maybe?

Today Ellipse behaves as a "stretched" circle (behaviour available everywhere in the vector panorama), but a real Ellipse is more "abstract" than a circle, so this could cover the scenario you described above.

 

Please forgive me if I wrote something stupid here  :)

 

Today I have very clever and flexible Ellipse Tool, with holes and sectors options, but cannot use it as much as I would, because the "create a 50px hole" is much more common scenario than "create a 25% hole". At least in my work this is what happens, so CMD+J and Operations are still my best friends  :)

The white dog, making tools for artists, illustrators and doodlers

Link to comment
Share on other sites

  • Staff

No, nothing stupid about that.

 

I know our donut is a simple form.  This is not entirely down to us being lazy, and more to do with conformity across all our shapes.  With the exception of the rounded rectangle, all other shapes express sizes in terms of a percentage of their dimensions.  This means that we don't have to project these sizes in separate axis based on their end transform - something which would become very difficult for the more complex shapes such as Cog and Star.

 

We do already have the ability to create the type of donut you are talking about - ellipse, with an inner stroke.  Expand stroke on this example would create quite a complex set of curves, though - and I try to keep the geometry as simple as possible for our Shapes.  So experimentation will be needed as I wouldn't just use the same code as expanding strokes.

Again, shear would have to be ignored in any projections, so an object with shear will produce incorrect sizes.

SerifLabs team - Affinity Developer
  • Software engineer  -  Photographer  -  Guitarist  -  Philosopher
  • iMac 27" Retina 5K (Late 2015), 4.0GHz i7, AMD Radeon R9 M395
  • MacBook (Early 2015), 1.3GHz Core M, Intel HD 5300
  • iPad Pro 10.5", 256GB
Link to comment
Share on other sites

I'm perfectly sure all we find now in AD/AP has been designed as a basement to make "future" implementations easier and much more performant.

All you wrote make me think about live projection of these shapes on isometric/dimetric grids at certain point, and this makes me happy...  :)

The white dog, making tools for artists, illustrators and doodlers

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.