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

Crashing when trying to add a curve to a polyline segment #5173

Open
chad21mycoopers opened this issue Feb 1, 2025 · 4 comments
Open

Crashing when trying to add a curve to a polyline segment #5173

chad21mycoopers opened this issue Feb 1, 2025 · 4 comments

Comments

@chad21mycoopers
Copy link

Using Windows 64bit latest version 2024.02. Uninstalled and reinstalled did not fix the crash. Occurred on two different computers.

Create a fresh brand new show directory
Open xLights
Map to the new show directory
Go to Layout tab
Click 3D checkbox
Click Import
Click space to import and select the Tree Top 200.xmodel in the attached zip folder.
Right Click on last segment on the top of the model.
Add Curve

CRASH..
I think it has something to do with the Corners being 'Leading Segment'.
I have modified the Corners to 'Neither' and it seems to resolve the crash.

xLightShowsBackup2.zip

@derwin12
Copy link
Collaborator

derwin12 commented Feb 1, 2025

Not crashing here. (assume you mean 2025.02)
Anything about your configuration?

Can you do a tools->package logs.

Image

@derwin12
Copy link
Collaborator

derwin12 commented Feb 1, 2025

Where are you clicking? where is the spot you are adding a curve? I am not that familiar with what you are doing here and am perhaps missing what you are doing.

@derwin12
Copy link
Collaborator

derwin12 commented Feb 1, 2025

This crashed..

Image

@derwin12
Copy link
Collaborator

derwin12 commented Feb 2, 2025

Can duplicate it .. havent found the answer though..

        while (current_pos > seg_end) {
            sub_segment++;
            seg_start = seg_end;
            segment_length = isCurve ? pPos[segment].curve->GetSegLength(sub_segment) : 1.0f;   // return 0.0 and subsegment goes crazy
            if(segment_length == 0.0f) {
                segment_length = 1.0f;
                break;
            }
            seg_end = seg_start + segment_length;
        }
        glm::vec3 v;
        if (isCurve) {
            v = glm::vec3(*pPos[segment].curve->GetMatrix(sub_segment) * glm::vec4((current_pos - seg_start) / segment_length, 0, 0, 1));
        } else {
            v = glm::vec3(*pPos[segment].matrix * glm::vec4(current_pos / polyLineSizes[segment], 0, 0, 1));
        }

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants