Developer Guide

.NET, WPF & C++ Chart Architecture, Data Handling and Performance

developer guide
.net chart
wpf chart
c# chart component
scientific chart
winform chart
charting component
chart control

Developer Guide
.NET, WPF & C++ Chart Architecture, Data Handling and Performance

This guide covers everything you need to build professional charts with ProEssentials — from choosing the right chart object, to handling data efficiently, to GPU-accelerated real-time streaming. ProEssentials is a native .NET and C++ charting component with Direct2D, Direct3D, and GdiPlus rendering, engineered for the fewest CPU/GPU cycles and the fastest chart rendering available. Whether you're building a WinForm chart, a WPF chart, or an MFC C++ visualization, this is your technical reference.

Choosing a Chart Object

Every ProEssentials implementation starts by choosing one of five chart objects. This choice drives the entire implementation — data model, axis behavior, plotting methods, and available features. Choose based on your data and visualization goal.

Pego — Graph Object 37 examples

The standard .NET chart control for categorical and sequential X-axis data. Supports bar, line, area, stacked bar, stacked area, OHLC, high-low-close, ribbon, and 27 total plotting methods. X-axis labels are set via a PointLabels string array — no numeric X data array needed.

Use for: Dashboards, bar charts, financial OHLC/candlestick, categorical comparisons, uniformly spaced time series.

Pesgo — Scientific Graph Object 50 examples

The scientific chart component for continuous numeric X-axis data. Supports scatter, line, spline, bubble, area, contour/heatmap, and 26 total plotting methods. Requires explicit X data arrays with PeData.X[subset, point] values. Supports jagged data (subsets with different point counts), contour rendering, and the most extensive real-time streaming options.

Use for: Scientific data visualization, XY scatter plots, real-time streaming charts, time-series with irregular intervals, contour and heatmap charts, bubble charts.

Pe3do — 3D Scientific Graph 18 examples

Renders 3D surfaces, wireframe, 3D contour, 3D bar charts, and 3D scatter plots using X, Y, and Z data arrays with Direct3D rendering. Y is the vertical (elevation) axis. Supports real-time 3D surface animation via AppendData (scrolling surface) or AppendSubset (waterfall).

Use for: 3D surface plots, wireframe visualizations, topographic contour, 3D waterfall charts, terrain rendering.

Pepso — Polar / Smith Object 7 examples

The polar coordinate chart component for angular data. Supports polar line, polar scatter, radar/spider charts, rose diagrams, and Smith charts for RF engineering. Data is expressed as angle and magnitude.

Use for: Polar coordinate plots, radar/spider charts, rose diagrams, Smith charts, RF impedance visualization.

Pepco — Pie Chart Object 4 examples

Renders pie charts, doughnut charts, and multi-ring charts with exploded slices, percent labels, and legend integration. Single data array for slice values.

Use for: Pie charts, doughnut charts, proportional data visualization.

Data Handling Patterns

ProEssentials provides six data loading patterns, chosen based on dataset size and performance requirements. Data is organized as Subsets (series/lines) × Points (data values). Set PeData.Subsets and PeData.Points first, then populate data arrays. Best practice: keep data preparation separate from chart API code — build your arrays from your data sources first, then pass completed arrays to ProEssentials.

Pattern 1: Direct Indexing Under 10K points

Assign values one at a time with PeData.Y[subset, point] = value. For Pesgo, also set PeData.X. For Pe3do, also PeData.Z. Simple and clear — best for demos and small static datasets.

Pattern 2: FastCopy Under 250K points

Build a float array in your code, then call PeData.Y.FastCopyFrom(array). Avoids per-element interop overhead. Overloads exist for 1D, 2D, and jagged arrays.

Pattern 3: UseDataAtLocation 250K+ points, zero-copy

Points the chart directly at your managed array — no data copy at all. Call PeData.Y.UseDataAtLocation(array, bufferSize). Best for very large datasets, shared data across multiple charts, or real-time scenarios.

Pattern 4: AppendData Streaming / real-time

Call PeData.Y.AppendData(newValues, amountPerSubset) to push new data. Automatically shifts existing data. Combine with CircularBuffers for ring-buffer performance at 100K+ data points.

Pattern 5: BindData Database / DataReader

Load directly from ADO.NET DataReader or DataView with PeData.Y.BindData(). Convenient for database-driven chart applications.

Pattern 6: Jagged Data Variable-length subsets

Enable PeData.JaggedData = true when subsets have different point counts. Requires RenderEngine = Direct2D. Three sub-methods: direct indexing, CopyFromJagged, or UseJaggedDataAtLocation.

DuplicateData Optimization: When all subsets share identical X data (common in Pesgo), set PeData.DuplicateDataX = DuplicateData.PointIncrement. Provide X data for only subset 0 — the chart reuses it for all subsets, eliminating redundant storage.

Real-Time Streaming

ProEssentials supports five real-time update strategies, from simple strip charts to GPU-accelerated high-frequency streaming at millions of data points.

Essential Setup (all real-time charts): PeConfigure.PrepareImages = true, PeConfigure.CacheBmp = true (caches static elements for flicker-free repainting), PeSpecial.AutoImageReset = false (skip automatic dirty checks). Manual axis scaling is strongly recommended to avoid per-tick min/max scanning of the entire dataset.

AppendData Strip Chart

Shifts existing data, adds new at the edge. The most common real-time pattern. Works with Pego, Pesgo, and Pe3do. Combine with CircularBuffers for 100K+ point ring-buffer performance.

FastCopyFrom Full Replace

Replace all data every tick. Best for oscilloscope-style waveform displays where the entire buffer changes simultaneously. Example: 4 subsets × 100K points = 400K values replaced per tick.

Direct Index Circular Write

Write directly by index, wrap counter at buffer end. No shifting, no appending — just overwrite in place. Good for circular displays.

AppendSubset Waterfall

Pe3do only. Adds a new complete subset each tick, producing 3D waterfall visualizations. Each tick adds a new row to the waterfall.

UseDataAtLocation Zero-Copy

Application manages its own memory; chart reads it directly. No copy overhead. Combine with CircularBuffers and AppendData — ProEssentials appends into your local memory using circular pointers. Example: 4 subsets × 2M points with zero-copy.

GPU Performance Features

ProEssentials delivers the fastest chart rendering available through native Direct2D and Direct3D rendering with GPU acceleration. These features can be combined for maximum throughput.

ComputeShader

PeData.ComputeShader = true. Offloads chart construction to the GPU — potentially 2000+ cores vs a single CPU thread. Applies to Pesgo and Pe3do with Direct3D render engine. Produces dramatic speedup for large datasets where chart geometry is built on the GPU rather than the CPU.

Filter2D3D

PeData.Filter2D3D = true (Pesgo only). Two-tier ComputeShader pipeline: first pre-filters sequential 2D line data losslessly, then the final shader constructs the scene. Dramatic speed improvement for 250K+ point line charts. Use with ComputeShader = true.

CircularBuffers

PeData.CircularBuffers = true. Uses a ring-buffer pointer instead of shifting memory on each AppendData call. Essential for real-time streaming with 100K+ data points. Works with Pego, Pesgo, Pepso, and Pe3do.

StagingBuffers

PeData.StagingBufferX/Y/Z = true. Keeps GPU-side copies of data arrays for efficient CPU-to-GPU transfer pipeline. Enable per axis that is being updated during real-time rendering.

Rendering Engines

Three render engines: Direct2D, Direct3D, and GdiPlus. Direct3D enables ComputeShader and full GPU acceleration. Direct2D supports jagged data and advanced 2D rendering. GdiPlus is the legacy fallback with broadest compatibility.

Architecture & Property Interface

ProEssentials uses a hierarchical property interface. All chart configuration is through nested property objects accessed from the chart control. This architecture applies equally to .NET chart, WPF chart, and C++ DLL development.

Hierarchical Property Groups

Property groups: PeData (data arrays, counts, modes), PePlot (plotting method, visual options), PeGrid (axis scales, grid lines, zoom), PeColor (colors for all elements), PeString (labels, titles), PeFont (font sizing), PeAnnotation (reference lines, graph annotations, axis annotations), PeUserInterface (interaction, cursors, hotspots, scrollbars), PeConfigure (rendering, caching), PeFunction (actions — reinitialize, print, zoom, export), PeTable (data table below chart), PeLegend (legend configuration).

Enum-Driven Configuration

Enum-Driven Configuration: Most behavioral settings use enums — never hardcode integer values. Key enums include GraphPlottingMethod, SGraphPlottingMethod, ManualScaleControl, ViewingStyle, QuickStyle, RenderEngine, AllowZooming, MultiAxisStyle, CursorMode, and CursorPromptStyle. Important: PePlot.Method uses a different enum for each chart object.

Rendering Pipeline

Rendering Pipeline: PeConfigure.CacheBmp = true should always be set — it caches the rendered image in memory for flicker-free repainting. PeFunction.ReinitializeResetImage() performs a full rebuild after data changes. PeFunction.ResetImage(0,0) rebuilds the image only after visual changes. ProEssentials includes AI-type logic that automatically prevents odd-looking charts through intelligent axis scaling, label placement, legend layout, and grid line spacing.

Two API Layers

Two API Layers: The .NET property interface and C++ DLL interface are interchangeable — both access the same native engine. .NET is standard for C#/VB/WPF. The DLL interface is used for MFC C++, Delphi, and special cases. PeSpecial.HObject provides the native DLL handle for interop scenarios.

Annotations & Labels

ProEssentials provides a comprehensive annotation system for adding reference lines, text markers, callout labels, shapes, and data tables to any chart.

Line Annotations

Line Annotations: Horizontal and vertical reference lines at data coordinates. Set PeAnnotation.Line.YAxis[i] for horizontal lines, PeAnnotation.Line.XAxis[i] for vertical lines. Supports 16+ line styles, per-annotation colors, text labels, and zoom-window visibility control.

Graph Annotations

Graph Annotations: Place symbols, text, lines, shapes, and bitmaps at arbitrary data coordinates. Supports angled text, connected lines, text dodging (auto-avoidance), composite patterns, bitmaps, and per-annotation formatting. Independent of chart data — use for callout labels, overlay markers, and decorative elements.

Table Annotations

Table Annotations: Up to 20 independent positioned table elements that can appear inside axis regions, at chart edges, or aligned with data points. Support multi-column and multi-row layouts with individual cell formatting. Used for custom legends, data summaries, and info panels.

Quick Annotations

Quick Annotations: Temporary graph annotations rendered via an optimized path that avoids full image rebuilds. Ideal for measurement overlays, drag rectangles, crosshairs, and transient UI that updates on every mouse move.

User Interaction & Events

ProEssentials fires .NET events for user interactions including data hotspot clicks, cursor tracking, zoom changes, and custom event handling. Key patterns include pixel-to-data coordinate conversion (ConvPixelToGraph), hotspot detection for clickable chart regions, and cursor tracking with configurable tooltip styles. Supports mouse wheel zoom, interactive data scrolling, and popup menu customization.

Multi-Axis Charts

Multi-Axis Charts: Display multiple Y axes on a single chart. Each axis gets its own scale, grid numbers, label, and color. Subsets are assigned to axes via MultiAxisStyle and WorkingAxis properties. Supports both separate graph-area and overlapping axis layouts.

Zoom and Scroll

Zoom and Scroll: Pesgo supports three independent axis control levels — auto-scaled, manually scaled, and zoom-controlled. Zoom overlays manual scaling without changing manual values. Pego uses PointsToGraph for scrollbar-based navigation. Interactive zoom is controlled via AllowZooming enum and mouse wheel configuration.

Date/Time Axes

Date/Time Axes: ProEssentials supports date/time X-axes through serial date values. Enable DateTimeMode on PeData, then pass dates as OLE Automation doubles. Supports both uniform time steps (DeltaX) and variable time steps (DeltasX array).

Styling and Appearance

Visual Styling: Colors are controlled through PeColor property group with per-series SubsetColors, graph area colors, axis colors, and grid line transparency. Quick visual themes via ViewingStyle and QuickStyle enums. Font sizing uses a proportional control system. Data visualization features include 3D shadow effects, configurable point sizes, line styles, and bar width/gap control.

Printing and Export

Printing and Export: Programmatic printing via PeFunction.PrintGraph() and PeFunction.PrintGraphEx() with orientation and margin control. Image export to BMP, JPG, PNG, EMF, and SVG formats. Clipboard copy support. All export respects the current render engine for consistent output.

AI-Assisted Development

ProEssentials includes a Python-powered AI assistance system that gives any AI assistant on-demand access to the complete API — with ground truth validation that prevents hallucinated property paths. The system includes pe_query.py (15+ query commands), 32 knowledge files, 116 code examples, and structured JSON data covering 1,104 properties, 1,260 methods, and 167 enums.

AI Code Assistant Setup

Knowledge File Downloads

These AI knowledge files are included with your ProEssentials installation and are also available for download here. Load them into Claude AI Projects or your preferred AI tool for AI-assisted ProEssentials development.

Architecture & Fundamentals

Chart Object Patterns

Axes & Scaling
Annotations & Labels

Interaction & Events

Appearance & Output

Query Tool & Data Files

Supported Platforms

ProEssentials supports C# .NET 8.0 (WinForms and WPF), VB.NET, MFC C++, Embarcadero Delphi, C++ Builder VCL, and Excel/Access OCX development. Deployment requires a single native DLL (PEGRP64H.DLL) alongside your application. The .NET wrapper assemblies are available as local NuGet packages or direct assembly references. ProEssentials x64 assemblies are recommended for best performance.

Our Mission

Your success is our #1 goal by providing the easiest and most professional benefit to your organization and end-users.

We are Engineers

ProEssentials was born from professional Electrical Engineers needing their own charting components. Join our large list of top engineering companies using ProEssentials.

Thank You

Thank you for being a ProEssentials customer, and thank you for researching the ProEssentials charting engine.