[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Gnash-dev] Patch suggestion

From: Udo Giacomozzi
Subject: [Gnash-dev] Patch suggestion
Date: Wed, 20 Sep 2006 21:00:12 +0200


I already announced in a mailing list post to strk that it might be
possible to optimize the tesselator in a way that straight lines are
not split in pieces.

Well, here is a patch that seems to work. File "server/shape.cpp",
line 50, change the method to:

void    edge::tesselate_curve() const
    // Send this segment to the tesselator.
    if (is_straight())
      tesselate::add_line_segment(m_ax, m_ay);
      tesselate::add_curve_segment(m_cx, m_cy, m_ax, m_ay);

Having a simple rectangle this leads to just one trapezoid as opposed
to 10 and should noticeably speed up movies with many straight lines.

I had no time to extensively test the patch, but it seems to work.

(Strk, I'll reply to your post tomorrow).


reply via email to

[Prev in Thread] Current Thread [Next in Thread]