Real time detection of curved lines with Hough Transform

Hi, I have to perform real time detection of curved lines on a video feed. I have try Hough Transform but it is not working to me, the detected lines are too fragmented. I have read I should use “General Hough Transform” instead of Hough Transform, but I do not know where to start. This is the code that I have at the moment:

// in header, edge and mergedLines are defined as ofImage.

void Filter::update(const ofVideoPlayer &video){
    reset(); // clean everything

    if(video.isFrameNew()) {
        //apply blur using ofxBlurUtils
        convertColor(blurredPixels, gray, CV_RGB2GRAY);

        //canny detection using ofxCv
        Canny(gray, edge, (double)cannyThreshold1.get(),
                          (double)cannyThreshold2.get(), 3);
        // this function merge the top border and the bottom border of the lines
        // into one. This is because the edge detection is returning the contour of the line,
        // but I need a line of 1 pixel.


void Filter::applyBlur(const ofVideoPlayer &video){
    // the blur effect is flipping the image upside down. Revert it
    //gray.draw(0,videoHeight, videoWidth, -videoHeight);
    video.draw(0,videoHeight, videoWidth, -videoHeight);
    //video.draw(0,0, videoWidth, videoHeight);

void Filter::applyHough(const ofImage& mergeLines){
    convertColor(mergedLines, mergedLinesBn, CV_RGB2GRAY);

    // to do, pass the merged lines instead of the edge one
    // add parameters.
    auto threshMat = toCv(mergedLinesBn);
    HoughLinesP(threshMat, lines, threshold, CV_PI/180, 10, minLineLength, maxLineGap);

void Filter::reset(){

void Filter::draw()
        for( size_t i = 0; i < lines.size(); i++ ){
            Vec4i l = lines[i];
            ofDrawLine(l[0], l[1], l[2], l[3]);

I am using ofxCV by @kylemcdonald. I have found these resources online,

In these two articles it is described a real time approach for detecting curves, and it is more or less what I am doing, (besides the fact that my lines are horizontal, white on a black background) meaning grayscale conversion and canny edge detection (i do not need to select the region of interest, luckily enough)., but it does not work good with curved lines.

Does someone have experience with this topic? does it worth to check GeneralizedHoughBallard or it is not the right approach for realtime? (i do not have cuda on this machine)

PS. I have already read Using pattern recognition to identify random shapes but same category by @Hennio but it covers a different scenario.