Searcharxiv⌕ Search

arXiv subjects

Jerry R. Van Aken

Publications and source records attributed to Jerry R. Van Aken.

5 recordsLinked to original sources

Drawing ellipses and elliptical arcs with piecewise cubic Bézier curve approximations

This tutorial explains how to use piecewise cubic Bézier curves to draw arbitrarily oriented ellipses and elliptical arcs. The geometric principles discussed here result in strikingly simple interfaces for graphics functions that can draw (approximate) circles, ellipses, and arcs of circles and ellipses. C++ source code listings are included for these functions. Their code size can be relatively small because they are designed to be used with a graphics library or platform that draws Bézier curves, and the library or platform is tasked with the actual rendering of the curves.

cs.GR↗

Alpha Blending with No Division Operations

Highly accurate alpha blending can be performed entirely with integer operations, and no divisions. To reduce the number of integer multiplications, multiple color components can be blended in parallel in the same 32-bit or 64-bit register. This tutorial explains how to avoid division operations when alpha blending with 32-bit RGBA pixels. An RGBA pixel contains four 8-bit components (red, green, blue, and alpha) whose values range from 0 to 255. Alpha blending requires multiplication of the color components by an alpha value, after which (for greatest accuracy) each of these products is divided by 255 and then rounded to the nearest integer. This tutorial presents an approximate alpha-blending formula that replaces the division operation with an integer shift and add -- and also enables the number of multiplications to be reduced. When the same blending calculation is carried out to high precision using double-precision floating-point division operations, the results are found to exactly match those produced by this approximation. C++ code examples are included.

cs.GR↗

A Fast Parametric Ellipse Algorithm

This paper describes a 2-D graphics algorithm that uses shifts and adds to precisely plot a series of points on an ellipse of any shape and orientation. The algorithm can also plot an elliptic arc that starts and ends at arbitrary angles. The ellipse algorithm described here is largely based on earlier papers by Van Aken and Simar [1,2], which extend Marvin Minsky's well-known circle algorithm [3,4,5] to ellipses, and show how to cancel out the sources of error in Minsky's original algorithm. A new flatness test is presented for automatically controlling the spacing between points plotted on an ellipse or elliptic arc. Most of the calculations performed by the ellipse algorithm and flatness test use fixed-point addition and shift operations, and thus are well-suited to run on less-powerful processors. C++ source code listings are included. Keywords: parametric ellipse algorithm, rotated ellipse, Minsky circle algorithm, flatness, elliptic arc, conjugate diameters, affine invariance

cs.GR↗

A High-Level Model of Neocortical Feedback Based on an Event Window Segmentation Algorithm

The author previously presented an event window segmentation (EWS) algorithm [5] that uses purely statistical methods to learn to recognize recurring patterns in an input stream of events. In the following discussion, the EWS algorithm is first extended to make predictions about future events. Next, this extended algorithm is used to construct a high-level, simplified model of a neocortical hierarchy. An event stream enters at the bottom of the hierarchy, and drives processing activity upward in the hierarchy. Successively higher regions in the hierarchy learn to recognize successively deeper levels of patterns in these events as they propagate from the bottom of the hierarchy. The lower levels in the hierarchy use the predictions from the levels above to strengthen their own predictions. A C++ source code listing of the model implementation and test program is included as an appendix.

cs.NE↗

A statistical learning algorithm for word segmentation

In natural speech, the speaker does not pause between words, yet a human listener somehow perceives this continuous stream of phonemes as a series of distinct words. The detection of boundaries between spoken words is an instance of a general capability of the human neocortex to remember and to recognize recurring sequences. This paper describes a computer algorithm that is designed to solve the problem of locating word boundaries in blocks of English text from which the spaces have been removed. This problem avoids the complexities of speech processing but requires similar capabilities for detecting recurring sequences. The algorithm relies entirely on statistical relationships between letters in the input stream to infer the locations of word boundaries. A Viterbi trellis is used to simultaneously evaluate a set of hypothetical segmentations of a block of adjacent words. This technique improves accuracy but incurs a small latency between the arrival of letters in the input stream and the sending of words to the output stream. The source code for a C++ version of this algorithm is presented in an appendix.

cs.CL↗