Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Enhancement] Round corners set to zero issue #3384

Closed
coatsy35 opened this issue Sep 1, 2024 · 17 comments
Closed

[Enhancement] Round corners set to zero issue #3384

coatsy35 opened this issue Sep 1, 2024 · 17 comments
Assignees
Labels
enhancement New feature or request
Milestone

Comments

@coatsy35
Copy link

coatsy35 commented Sep 1, 2024

READ FIRST
https://github.com/Courseplay/Courseplay_FS22/wiki

Steps to reproduce
Field 30 on Vintage Oaks

Actual behavior
If you select sharpen corners on a field with 3 headlands and set the number of round corners to 0 you get two rounded corners then one sharp corner. If you set the rounded corners to 1, you then get one rounded corner and two sharp corners. See images below

Expected behavior
0 for round corners should force all corners to be sharp, ideally going off in a virtual line to create a virtual "90 degree" corner so the corner can be pulled out straight.

Screenshots
fsScreen_2024_09_01_22_55_53
fsScreen_2024_09_01_22_55_12

fsScreen_2024_09_01_22_56_16
fsScreen_2024_09_01_22_56_10

Courseplay version
Version used: 7.4.2.0

Log
https://drive.google.com/file/d/1Vw4reNx1F9_zwLrtajUH6741PCzfnddZ/view?usp=drive_link

Map
Vintage Oaks

Vehicles/ implements involved
Which vehicle or implement?
Mod yes/no ?

Relevant script mods
Mods like Autodrive or VCA and so on.

@coatsy35 coatsy35 added the bug Something isn't working label Sep 1, 2024
@pvaiko pvaiko added enhancement New feature or request and removed bug Something isn't working labels Sep 2, 2024
@pvaiko
Copy link
Contributor

pvaiko commented Sep 2, 2024

The generator only sharpens/rounds corners which have a radius less than the vehicle's turning radius. Corners, such as the one in your screen shot, already round with a radius above the vehicle's radius aren't changed.

If the expectation is sharpen these too, then we need to introduce another parameter as the generator will need to know what is the radius limit, under which sharpening should happen.

@coatsy35
Copy link
Author

coatsy35 commented Sep 2, 2024

The generator only sharpens/rounds corners which have a radius less than the vehicle's turning radius. Corners, such as the one in your screen shot, already round with a radius above the vehicle's radius aren't changed.

If the expectation is sharpen these too, then we need to introduce another parameter as the generator will need to know what is the radius limit, under which sharpening should happen.

I did think that might be the case of needing a parameter for it - would 0 on rounded corners be the basis for the new logic? That would be a great enhancement in time now you have got it all working so well.

PS. How do you know your vehicle turning radius? is there a place to check what it is for a mod or Giants machine?

@Tensuko
Copy link
Contributor

Tensuko commented Sep 3, 2024

I would love a more automatic logical system more, like the radius is always lower then vehicle turn radius or something.
The point is how to explain to ppl what to do.... will figure something out.

About Radius, there is a command for that, don't know wich right now.
For controlling the radius with a setting in vehicle menu, that must wait untill we have something for proper control it.
(Read value and never evern can set lower then the read value to make sure it always makes the turns and stuff).

@Tensuko Tensuko changed the title [BUG_SP] Round corners set to zero issue [Enhancement] Round corners set to zero issue Sep 5, 2024
@rohne83
Copy link
Contributor

rohne83 commented Sep 10, 2024

Don't understand the issue here. In the screenshots everything works as it should work. There's no possibility to make the outermost corner sharp as the field shape just does not allow it. Vehicle would have to go off the field here for what coatsy wants to have. If he wants that corner calculated sharp also for the outermost lane, he has to amend the field shape first by himself anyway (ploughing or with some script mods he can even do this with cultivators or sowing machines). Don't think it would be a good behaviour of CP course generator to go off the field shape due to some settings where people don't have such effect in mind.
As long as the radius is big enough to not leave empty spaces, the automatic decision for sharp vs round is the most appropriate way to go and so the courses above are totally correct in my eyes. I rather see issues with multitool courses in this kind of corners (imagine that corner with 3 tools and just one headland, instead of the 1 tool with 3 headlands).

@pvaiko
Copy link
Contributor

pvaiko commented Sep 10, 2024

I rather see issues with multitool courses in this kind of corners (imagine that corner with 3 tools and just one headland, instead of the 1 tool with 3 headlands).

With the new multitool implementation, if you select 1 round corner, only the vehicle working on the outermost headland will make a round corner.

@rohne83
Copy link
Contributor

rohne83 commented Sep 10, 2024

I rather see issues with multitool courses in this kind of corners (imagine that corner with 3 tools and just one headland, instead of the 1 tool with 3 headlands).

With the new multitool implementation, if you select 1 round corner, only the vehicle working on the outermost headland will make a round corner.

Really? That's great. Just have to wait until the general multitool bug is fixed then...

@coatsy35
Copy link
Author

Don't understand the issue here. In the screenshots everything works as it should work. There's no possibility to make the outermost corner sharp as the field shape just does not allow it. Vehicle would have to go off the field here for what coatsy wants to have. If he wants that corner calculated sharp also for the outermost lane, he has to amend the field shape first by himself anyway (ploughing or with some script mods he can even do this with cultivators or sowing machines). Don't think it would be a good behaviour of CP course generator to go off the field shape due to some settings where people don't have such effect in mind. As long as the radius is big enough to not leave empty spaces, the automatic decision for sharp vs round is the most appropriate way to go and so the courses above are totally correct in my eyes. I rather see issues with multitool courses in this kind of corners (imagine that corner with 3 tools and just one headland, instead of the 1 tool with 3 headlands).

@rohne83 @pvaiko

You would never want any form of short curve if you were ploughing (And I know we can't replicate everything as in IRL) but I have ploughed 1000's of acres and you always make the corner square unless it's a nice long smooth curve) I create a virtual line out of the corner in my head and head to it, the same with drilling actually or any other tool that doesn't like to follow curves unless they are very long and smooth such as tedding, spraying, fertiliser spreading.

In my image above the option of 0 needs removing really then, as currently it actually gives your two round corners if you pay attention to the image when set at 0. If you set it to 1 it works correctly and gives you 1 round corner.

@rohne83
Copy link
Contributor

rohne83 commented Sep 10, 2024

Yes, but as already said: if you want such corners to be completely sharp out until the last row, you should make that edge sharp manually before by yourself. CP will detect this and generate the course as you want. But it would never be a good behaviour of the course generator to generate a course going off the current field boundaries just because you set the number of round corners to 0.

@coatsy35
Copy link
Author

Yes, but as already said: if you want such corners to be completely sharp out until the last row, you should make that edge sharp manually before by yourself. CP will detect this and generate the course as you want. But it would never be a good behaviour of the course generator to generate a course going off the current field boundaries just because you set the number of round corners to 0.

You know, real GPS steering units have a feature called Square corners which do as I said, project a line out of the field. With an automated approach you would need to detect when the nose of the machine touches the field border and then reverse up. The part under your tractor not covered, is then covered by your next pass backing the implement up the same, to touch the field border.

Nice video here explaining it for anyone who cares to know how they work

https://youtu.be/psFpdSOZCQ0?si=nHdngzGsRetOOfso

@pvaiko
Copy link
Contributor

pvaiko commented Sep 10, 2024

As I said, the generator can do this, there is just no setting for it on the UI, like this corner (this a screenshot from out test tool):
image

@coatsy35
Copy link
Author

As I said, the generator can do this, there is just no setting for it on the UI, like this corner (this a screenshot from out test tool): image

Now that is cool! Wow. Really hope you decide to put a setting in for it at some point.

@Tensuko
Copy link
Contributor

Tensuko commented Sep 11, 2024

Every setting makes the generator more complex.
Some ppl already reported to me that they think its too many options but they just need to get used to it.
So I am 100% against adding another setting.

The question is, if we just turn that value all the way down to make sure:
Sharp corner is sharp corner, no matter what.

Since if you don't want sharp corners, you just turn it off and have that "very tiny rounded version".
For rounder corners, there is the round corner option.

So basically all situations that make sence can be done already, just that sharp at some point isn't always sharp.
That should be adressed if we can but without an unnecessary setting.

@coatsy35
Copy link
Author

Surely the too many options issue is addressed with the advanced vs non advanced options? Or what about having an external options file for those that like more control that can be turned on if required and most people would never mess with?

It would make sense to me as you say for that to not have another option but make the 0 round corners force sharp corners for all? Then if it doesn’t suit, you can just increase the number not altering anything else for people and keeping it simple still.

@rohne83
Copy link
Contributor

rohne83 commented Sep 11, 2024

So basically all situations that make sence can be done already, just that sharp at some point isn't always sharp. That should be adressed if we can but without an unnecessary setting.

But what will happen when you have several types of corners on same field, which is the case quite often? So i.e. you have corners as the one that coatsy showed in his screenshots, but also really sharp corners on same field. Most players would want the latter to be worked sharp indeed as that's what makes sense the most, but for the one which coatsy showed rather stick to the current behavior with the tool following the contour as long as its turning radius allows it (and rather amend the corner shape manually before course generation if you still want that corner to be worked sharp as well). Especially when you also have obstacles near the field edge it would be counterproductive if the tool went outside the defined field borders there.

@Tensuko
Copy link
Contributor

Tensuko commented Sep 11, 2024

In FS with all its different shaped fields and tools, the question "what if..." Has endless answers.
There is a point where we have to stop and say thats enough possibilitys.
Obstacles near field thats why we have round corners counted from 1st headland.

@rohne83
Copy link
Contributor

rohne83 commented Sep 12, 2024

That's why I say rather stick to current behaviour and let the actual field corner shape decide whether a corner can be worked sharp or only round. If coatsy wants those rounder corners being worked sharp as well, he can still use a plow so that next time the course will be generated with sharp corner also there. But the other way round all others wouldn't have the possibility to decide for sharp corner setting (I'd never use anything but sharp corners at all anymore) without risking the tool running off the field borders in by-field-shape rather round corners as the one above.

@coatsy35
Copy link
Author

For interests sake, JD have just released this video of their new software for field boundaries and row. Which shows what I was describing.

https://youtu.be/FTC8CPzvDAg?si=QSidxpdls-sETB4T&t=17

@Tensuko Tensuko added this to the 7.5.0.0 milestone Oct 26, 2024
@Tensuko Tensuko closed this as completed Oct 26, 2024
Tensuko added a commit that referenced this issue Oct 26, 2024
- Enhanced sharp corner detection when round corners is set to zero. #3384
- Better pocket handling with the new generator. #3536
- Fix for #3552
- Fix for #3540
- Fix for #3557
- Removed multitool option for vineyards. Fixing this is too complex and will be addressed later in FS25 #3550
- Some improvements for refill feature.
- Added changelog for the modhub update.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants