Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7023725
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T23:44:50+00:00 2026-05-27T23:44:50+00:00

Ok, here is exactly what i am trying to do. When i move my

  • 0

Ok, here is exactly what i am trying to do.

  • When i move my mouse over the surface, i collect the CVector2 points into std::vector

  • Those points shall create a Bezier Path for my object to follow it

At this point i have positions stored and i need to

  • Calculate the X,Z on this bezier path later on, so that my object will follow this path.

Now here is what i have:

  • Store all the points as the std::vector
  • And when engine ticks the object i :

// Return position on Bezier at current fTime

CVector3 CBezierPath::Calculate(const float& fTime) { CVector3
vPosition; … return vPosition; }

Yes, how do i calculate the position in fTime on a Bezier Path made from N number of points?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T23:44:51+00:00Added an answer on May 27, 2026 at 11:44 pm

    Ok found solution,

    Knowing that i have x number of waypoints, i generate Bezier curves where number of curves is equal to:

    iCurves = iWaypointsCount / 3

    Now after i calculate T for current curve i just skip to another curve and restart calculating to from 0 to 1.

       // If we are not finished on this curve
        if(m_fBezierT < 1.0)
        {
            m_vPosition = m_BezierPath.CalculateBezierPoint(m_iCurrentCurve, m_fBezierT);
    
            m_fBezierT += 0.3f * fDelta;
        }
        // Finished, go next curve
        else
        {
            // No more curves
            if(m_iCurrentCurve+1 >= m_BezierPath.GetCurveCount())
            {
                m_fBezierT = 1.0f;
            }
            // Switch to next Curve
            else
            {
                m_fBezierT = 0.0f;
                m_iCurrentCurve++;
            }
        }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am trying to do exactly what is being done over here: How do
I've been trying to figure out what exactly is happening here. I'm just trying
I'm not sure what exactly i'm doing wrong here...but i noticed that my File.Move()
I'm trying to put standard output from nmap into WPF window application (textbox exactly).
I've been trying to get this complex MYSQL query to work exactly right over
I'm trying to convert a Mercurial repository to move all the files into a
Here's the error I see when trying to load a .hs file into ghci.
I want to display a popup windo on my rails application... Here is exactly
I have followed this tutorial here as mentioned exactly I now try to run
Here is the link to the jsfiddle: http://jsfiddle.net/d3xMZ/ when I hover, it does exactly

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.