Skip to content

Video Fingerprinting SDK FAQ

Try it Download Windows trial dotnet add package VisioForge.DotNet.Core Pricing →

This comprehensive FAQ addresses the most common questions about the VisioForge Video Fingerprinting SDK. If you can't find your answer here, please visit our support forum or Discord community.

Table of Contents

Licensing Questions

Q: What's the difference between Trial and Commercial licenses?

A: The key differences are:

Feature Trial Commercial
Duration 30 days Perpetual
Watermark Yes (visual overlay) No
All Features Yes Yes
Production Use No Yes
Technical Support Forum only Email/Priority/Phone
Updates Trial period only 1 year

Q: Can I use the Trial license for development?

A: Yes! The trial license is perfect for development and testing. It includes all features with a watermark. You can develop your entire application with the trial license and purchase a commercial license when ready for production.

// Development environment
VFPAnalyzer.SetLicenseKey("TRIAL");

// Production environment
VFPAnalyzer.SetLicenseKey(Environment.GetEnvironmentVariable("VFP_LICENSE_KEY"));

Q: What happens when my trial expires?

A: After 30 days, the SDK will stop processing videos and return an error. Your code remains intact - simply purchase a license and update the key to continue.

Q: Are there any feature limitations with different licenses?

A: No, the commercial license includes all features without any limitations. The only difference between trial and commercial licenses is the watermark in trial mode.

Q: Can I use one license on multiple machines?

A: License terms depend on your purchase: - Developer (annual): One named developer; licenses are counted by developer, not by workstation - Workgroup (annual): Three named developers in one organization - Lifetime·Team: All developers in the purchasing organization at one location within one city - Custom and volume licensing: Available through sales for organizations that need different terms

Both paid license types include royalty-free distribution of applications built with the SDK. End users do not need separate runtime licenses. See the canonical licensing policy for current terms.

Q: How do I handle licensing in a distributed application?

A: Commercial licenses include royalty-free distribution, so customers running your application do not need separate runtime licenses. Keep purchased registration material private and apply it using the product's documented registration API. See the canonical licensing policy for current commercial terms.

Performance and Optimization

Q: How fast can the SDK process videos?

A: Processing speed depends on several factors:

Factor Impact on Speed
Video Resolution 4K: ~0.5x realtime, 1080p: ~2x realtime, 480p: ~5x realtime
CPU Cores Linear scaling up to 8 cores
Hardware Acceleration 2-5x faster with GPU support
Storage Type SSD provides 30-50% speed improvement
Fingerprint Type Search fingerprints are 2x slower than Compare

Typical benchmarks on modern hardware (Intel i7, 16GB RAM, SSD): - 1080p video: 60-120 seconds per hour of content - 720p video: 30-60 seconds per hour of content - 480p video: 15-30 seconds per hour of content

Q: How much memory does fingerprint generation require?

A: Memory usage scales with video resolution and duration:

// Approximate memory usage calculation
long EstimateMemoryUsage(int width, int height, int durationSeconds)
{
    // Base memory for decoder and buffers
    long baseMemory = 100 * 1024 * 1024; // 100 MB

    // Frame buffer memory (3-5 frames typically buffered)
    long frameSize = width * height * 3; // RGB
    long frameBuffers = frameSize * 5;

    // Fingerprint data (approximately 1KB per second)
    long fingerprintSize = durationSeconds * 1024;

    return baseMemory + frameBuffers + fingerprintSize;
}

// Example: 1080p video, 10 minutes
// Memory ≈ 100MB + (1920*1080*3*5) + (600*1KB) ≈ 131MB

Q: Can I process multiple videos simultaneously?

A: Yes, but with considerations:

public class ParallelProcessor
{
    private readonly SemaphoreSlim _semaphore;

    public ParallelProcessor(int maxConcurrency = 4)
    {
        // Limit based on CPU cores and available memory
        _semaphore = new SemaphoreSlim(maxConcurrency);
    }

    public async Task ProcessMultipleVideos(string[] videoPaths)
    {
        var tasks = videoPaths.Select(ProcessVideoAsync);
        await Task.WhenAll(tasks);
    }

    private async Task ProcessVideoAsync(string videoPath)
    {
        await _semaphore.WaitAsync();
        try
        {
            var source = new VFPFingerprintSource(videoPath)
            {
                // Reduce resolution for parallel processing
                CustomResolution = new Size(640, 480)
            };

            var fp = await VFPAnalyzer.GetComparingFingerprintForVideoFileAsync(source);
            // Process fingerprint...
        }
        finally
        {
            _semaphore.Release();
        }
    }
}

Recommended concurrency: - 8GB RAM: 2-3 concurrent videos - 16GB RAM: 4-6 concurrent videos - 32GB RAM: 8-12 concurrent videos

Q: How can I optimize for real-time processing?

A: For real-time or near real-time processing:

  1. Lower the work per frame — VFPFingerprintSource does not expose UseHardwareAcceleration or HardwareDevice properties. To accelerate the fingerprinting itself, transcode the source to a lower resolution upstream (e.g., scale to 480p) before passing it to VFPAnalyzer:

    var source = new VFPFingerprintSource(videoPath)
    {
        CustomResolution = new Size(480, 360)
    };
    

  2. Process in segments (the VFPFingerprintSource ctor requires a path on disk — FileNotFoundException is thrown for URLs/streams; segment a saved capture, not a live RTSP URL):

    // Process 30-second segments of a captured local file
    var source = new VFPFingerprintSource(localCapturePath)
    {
        StartTime = TimeSpan.FromSeconds(segmentIndex * 30),
        StopTime = TimeSpan.FromSeconds((segmentIndex + 1) * 30),
        CustomResolution = new Size(480, 360) // Lower resolution
    };
    

  3. Crop / mask non-essential regions — VFPFingerprintSource has no FrameRate knob. To analyze fewer frames per second, transcode the source first; or trim the analyzed area with CustomCropSize / IgnoredAreas to speed up per-frame work without dropping frames.

Accuracy and Detection

Q: How accurate is the video matching?

A: Accuracy depends on the transformation type:

Transformation Detection Rate False Positive Rate
Re-encoding 99.9% <0.1%
Resolution change 99.5% <0.1%
Watermark/Logo overlay 98% <0.5%
Cropping (< 20%) 95% <1%
Color adjustment 93% <2%
Heavy compression 90% <3%
Combined transformations 85-95% <5%

Q: What similarity threshold should I use?

A: Threshold recommendations based on use case:

// VFPAnalyzer.Compare: a match is a difference below the threshold
const int CompareThreshold = 300; // DVS demo and vfp_compare default; CompareVideoFilesAsync uses 500

// VFPAnalyzer.Search / SearchAsync (maxDifference)
const int SearchThreshold = 500;  // MMT demo default; MMT Live uses 1100

public bool IsMatch(int difference, int threshold)
{
    return difference < threshold;
}

Use cases: - Copyright detection and duplicate finding (Compare): start at 300; raise it toward 500 if re-encoded copies are missed, lower it if unrelated videos match - Finding clips or ads in a longer video (Search): start at 500; the MMT demo slider covers 200-1000, and MMT Live uses 1100 for live streams - The score is not a percentage, so tune the threshold on your own content

Q: Can the SDK detect partial matches?

A: Yes! The SDK excels at finding video fragments:

// Search for a 30-second clip in a 2-hour movie
var searchFp = await VFPAnalyzer.GetSearchFingerprintForVideoFileAsync(
    new VFPFingerprintSource("clip.mp4")
);

var mainFp = await VFPAnalyzer.GetSearchFingerprintForVideoFileAsync(
    new VFPFingerprintSource("movie.mp4")
);

// VFPAnalyzer.SearchAsync requires the full 5-arg form; the result is List<TimeSpan>,
// each entry is the match start time within mainFp.
var results = await VFPAnalyzer.SearchAsync(
    searchFp,
    mainFp,
    searchFp.Duration,
    maxDifference: 500,
    allowMultipleFragments: true);

foreach (var matchStart in results)
{
    Console.WriteLine($"Found match starting at {matchStart}");
}

Q: How does the SDK handle different aspect ratios?

A: The SDK normalizes aspect ratios automatically, but you can improve accuracy:

// For videos with letterboxing/pillarboxing
// IgnoredAreas is `{ get; private set; }` of List<Rect> — populate via .Add(...).
// Rect ctor is (left, top, right, bottom), not (x, y, width, height).
var source = new VFPFingerprintSource(videoPath);
source.IgnoredAreas.Add(new Rect(0, 0, 1920, 140));      // Top letterbox
source.IgnoredAreas.Add(new Rect(0, 940, 1920, 1080));   // Bottom letterbox

// Or restrict the analysis area to a fixed crop window via CustomCropSize.
// (No AutoCropBlackBars property exists — set CustomCropSize manually if you
// want to drop letterbox bars before fingerprinting.)
var croppedSource = new VFPFingerprintSource(videoPath)
{
    CustomCropSize = new Rect(0, 140, 1920, 940)         // Use only the central 1920x800 frame
};

Q: Can it detect mirrored or rotated videos?

A: The SDK can detect: - ✅ Horizontal and vertical mirroring, and 180 degree rotation (Compare and Search check these orientations automatically) - ✅ Minor rotations (< 5 degrees) - ⚠️ 90 and 270 degree rotations (requires manual preprocessing)

// For mirrored video detection
public async Task<bool> CheckMirroredMatch(string video1, string video2)
{
    var fp1 = await GenerateFingerprint(video1);
    var fp2 = await GenerateFingerprint(video2);

    // VFPAnalyzer.Compare also checks the mirrored orientations of fp2
    return VFPAnalyzer.Compare(fp1, fp2, TimeSpan.FromSeconds(5)) < 300;
}

Supported Formats and Codecs

Q: What video formats are supported?

A: The SDK supports virtually all common formats through GStreamer:

Container Formats: - MP4, M4V, MOV - AVI, WMV, ASF - MKV, WebM - FLV, F4V - MPEG, MPG, M2TS, TS - 3GP, 3G2 - OGV, OGG - And many more...

Video Codecs: - H.264/AVC - H.265/HEVC - VP8, VP9 - MPEG-1, MPEG-2, MPEG-4 - WMV7, WMV8, WMV9 - ProRes, DNxHD - AV1 (with plugin)

Q: Are there any format limitations?

A: Some limitations exist:

  1. DRM-protected content: Cannot process encrypted videos
  2. Rare codecs: May require additional GStreamer plugins
  3. Corrupted files: Partial processing possible with error handling
  4. Live streams: Supported but requires segmented processing

Q: What about audio-only files?

A: The Video Fingerprinting SDK requires video content.

Platform Compatibility

Q: Which platforms are supported?

A: Full platform support matrix:

Platform Architecture .NET Version Status
Windows 10/11 x86, x64 .NET Framework 4.6.1+, .NET 6+ ✅ Full Support
Windows 10/11 ARM64 .NET 6+ (a .NET Framework app runs as x86, or as x64 on Windows 11) ✅ Full Support
Windows Server 2016+ x64 .NET Framework 4.6.1+, .NET 6+ ✅ Full Support
Ubuntu 20.04+ x64, ARM64 .NET 6+ ✅ Full Support
Debian 11+ x64, ARM64 .NET 6+ ✅ Full Support
RHEL/CentOS 8+ x64 .NET 6+ ✅ Full Support
macOS 12+ x64, ARM64 .NET 9+ ✅ Full Support
Docker/Kubernetes Linux-based .NET 6+ ✅ Full Support

On .NET 5+ the target framework selects the platform build: -windows on Windows (net8.0-windows), -macos on macOS (net9.0-macos or later). A target framework without an OS suffix (net8.0) is the Linux build.

Q: Can I use the SDK in Docker containers?

A: Yes! Here's a sample Dockerfile:

FROM mcr.microsoft.com/dotnet/runtime:6.0 AS base
WORKDIR /app

# Install GStreamer and dependencies
RUN apt-get update && apt-get install -y \
    libgstreamer1.0-0 \
    gstreamer1.0-plugins-base \
    gstreamer1.0-plugins-good \
    gstreamer1.0-plugins-bad \
    gstreamer1.0-plugins-ugly \
    gstreamer1.0-libav \
    && rm -rf /var/lib/apt/lists/*

FROM mcr.microsoft.com/dotnet/sdk:6.0 AS build
WORKDIR /src
COPY ["YourProject.csproj", "."]
RUN dotnet restore
COPY . .
RUN dotnet build -c Release -o /app/build

FROM build AS publish
RUN dotnet publish -c Release -o /app/publish

FROM base AS final
WORKDIR /app
COPY --from=publish /app/publish .
ENTRYPOINT ["dotnet", "YourProject.dll"]

Q: Are there platform-specific performance differences?

A: The fingerprinting algorithm is the same portable code on every platform and runs on the CPU, so its speed depends on the processor rather than on the operating system. Decoding the source video adds its own cost, which depends on the file and on the platform's decoders. To size a deployment, measure on the target hardware.

Q: Can I use the SDK in cloud environments?

A: Yes, the SDK works in all major cloud platforms:

AWS:

// Use GPU instances for better performance
// Recommended: g4dn.xlarge or p3.2xlarge

Azure:

// Use NCv3-series or NVv4-series VMs
// Enable GPU acceleration in container instances

Google Cloud:

// Use N1 with NVIDIA Tesla GPUs
// Or A2 machine series for best performance

Integration and Development

Q: Can I use the SDK in a web application?

A: Yes, for server-side processing in ASP.NET Core on Windows or Linux (on Windows, add -windows to the target framework, e.g. net8.0-windows: without an OS suffix it is the Linux build):

public class VideoFingerprintService
{
    private readonly ILogger<VideoFingerprintService> _logger;

    public VideoFingerprintService(ILogger<VideoFingerprintService> logger)
    {
        _logger = logger;
        VFPAnalyzer.SetLicenseKey(Environment.GetEnvironmentVariable("VFP_LICENSE"));
    }

    public async Task<IActionResult> ProcessUpload(IFormFile file)
    {
        var tempPath = Path.GetTempFileName();
        try
        {
            using (var stream = new FileStream(tempPath, FileMode.Create))
            {
                await file.CopyToAsync(stream);
            }

            var fingerprint = await GenerateFingerprint(tempPath);
            // Store fingerprint in database

            return Ok(new { Success = true, FingerprintId = fingerprint.Id });
        }
        finally
        {
            File.Delete(tempPath);
        }
    }
}

Q: How do I implement a progress bar?

A: Use the progress callback:

public class ProgressTracker
{
    public event EventHandler<int> ProgressChanged;

    public async Task<VFPFingerPrint> ProcessWithProgress(string videoPath)
    {
        var source = new VFPFingerprintSource(videoPath);

        return await VFPAnalyzer.GetComparingFingerprintForVideoFileAsync(
            source,
            errorDelegate: (error) => {
                Console.WriteLine($"Error: {error}");
            },
            progressDelegate: (progress) => {
                ProgressChanged?.Invoke(this, progress);
            }
        );
    }
}

// Usage in WPF/WinForms
tracker.ProgressChanged += (s, progress) => {
    Dispatcher.Invoke(() => {
        progressBar.Value = progress;
        labelStatus.Text = $"Processing: {progress}%";
    });
};

Database and Storage

Q: How should I store fingerprints in a database?

A: Best practices for database storage:

// SQL Server example
public class FingerprintRepository
{
    public async Task SaveFingerprint(VFPFingerPrint fp, string videoId)
    {
        // Option 1: Store as binary
        byte[] data = fp.Save();

        using var connection = new SqlConnection(connectionString);
        await connection.ExecuteAsync(
            @"INSERT INTO Fingerprints (VideoId, Data, Duration, Width, Height, Created)
              VALUES (@VideoId, @Data, @Duration, @Width, @Height, @Created)",
            new {
                VideoId = videoId,
                Data = data,
                Duration = fp.Duration.TotalSeconds,
                Width = fp.Width,
                Height = fp.Height,
                Created = DateTime.UtcNow
            });
    }

    public async Task<VFPFingerPrint> LoadFingerprint(string videoId)
    {
        using var connection = new SqlConnection(connectionString);
        var data = await connection.QuerySingleAsync<byte[]>(
            "SELECT Data FROM Fingerprints WHERE VideoId = @VideoId",
            new { VideoId = videoId });

        return VFPFingerPrint.Load(data);
    }
}

// MongoDB example
public class MongoFingerprintRepository
{
    private readonly IMongoCollection<FingerprintDocument> _collection;

    public async Task SaveFingerprint(VFPFingerPrint fp, string videoId)
    {
        var document = new FingerprintDocument
        {
            VideoId = videoId,
            Data = Convert.ToBase64String(fp.Save()),
            Metadata = new FingerprintMetadata
            {
                Duration = fp.Duration,
                Width = fp.Width,
                Height = fp.Height,
                FrameRate = fp.FrameRate
            }
        };

        await _collection.InsertOneAsync(document);
    }
}

Q: How much storage space do fingerprints require?

A: Fingerprint sizes are predictable:

Fingerprint Type Size Formula Example (10 min video)
Compare ~100 bytes/second ~60 KB
Search ~1 KB/second ~600 KB
With thumbnails +10 KB/minute ~660 KB

Storage planning:

public long EstimateStorageNeeded(int videoCount, double avgDurationMinutes)
{
    // Search fingerprints (worst case)
    long bytesPerMinute = 60 * 1024; // 60 KB
    long fingerprintSize = (long)(bytesPerMinute * avgDurationMinutes);

    // Add 20% overhead for metadata
    long totalPerVideo = (long)(fingerprintSize * 1.2);

    // Total storage needed
    return videoCount * totalPerVideo;
}

// Example: 10,000 videos, 30 minutes average
// Storage ≈ 10,000 * (60KB * 30 * 1.2) = ~21 GB

Q: Should I use file system or database storage?

A: Depends on your requirements:

Storage Type Pros Cons Best For
File System Fast, simple, easy backup Hard to query, no transactions < 10,000 videos
SQL Database ACID, queryable, metadata Slower, size limits 10,000 - 100,000 videos
NoSQL Database Scalable, flexible Complex setup > 100,000 videos
Object Storage (S3) Unlimited scale, cheap Network latency Archive/backup

Hybrid approach (recommended for large scale):

public class HybridStorage
{
    // Metadata in database for fast queries
    private readonly SqlConnection _db;

    // Fingerprint data in object storage
    private readonly IS3Client _s3;

    public async Task SaveFingerprint(VFPFingerPrint fp, VideoMetadata metadata)
    {
        // Save fingerprint to S3
        string s3Key = $"fingerprints/{metadata.VideoId}.vfp";
        await _s3.PutObjectAsync(s3Key, fp.Save());

        // Save metadata to database
        await _db.ExecuteAsync(
            @"INSERT INTO Videos (Id, Title, Duration, S3Key)
              VALUES (@Id, @Title, @Duration, @S3Key)",
            new {
                metadata.Id,
                metadata.Title,
                metadata.Duration,
                S3Key = s3Key
            });
    }
}

Q: How do I debug performance issues?

A: Use profiling and metrics:

public class PerformanceMonitor
{
    public async Task<FingerprintMetrics> ProcessWithMetrics(string videoPath)
    {
        var metrics = new FingerprintMetrics();
        var sw = Stopwatch.StartNew();

        // Check file size
        var fileInfo = new FileInfo(videoPath);
        metrics.FileSize = fileInfo.Length;

        // Monitor memory before
        long memoryBefore = GC.GetTotalMemory(false);

        var source = new VFPFingerprintSource(videoPath);
        var fingerprint = await VFPAnalyzer.GetComparingFingerprintForVideoFileAsync(
            source,
            progressDelegate: (progress) => {
                if (progress % 10 == 0)
                {
                    long currentMemory = GC.GetTotalMemory(false);
                    Console.WriteLine($"Progress: {progress}%, Memory: {currentMemory / 1024 / 1024} MB");
                }
            }
        );

        sw.Stop();

        metrics.ProcessingTime = sw.Elapsed;
        metrics.MemoryUsed = GC.GetTotalMemory(false) - memoryBefore;
        metrics.ProcessingSpeed = fileInfo.Length / sw.Elapsed.TotalSeconds;

        Console.WriteLine($"Performance Report:");
        Console.WriteLine($"  File Size: {metrics.FileSize / 1024 / 1024} MB");
        Console.WriteLine($"  Processing Time: {metrics.ProcessingTime}");
        Console.WriteLine($"  Memory Used: {metrics.MemoryUsed / 1024 / 1024} MB");
        Console.WriteLine($"  Speed: {metrics.ProcessingSpeed / 1024 / 1024} MB/s");

        return metrics;
    }
}

Additional Resources

Contact Support

If you can't find an answer in this FAQ:

  1. Search the forum: https://support.visioforge.com/
  2. Join Discord: https://discord.com/invite/yvXUG56WCH
  3. Email support: support@visioforge.com (commercial licenses)
  4. Report bugs: GitHub Issues

When contacting support, please include: - SDK version - Platform and .NET version - License type - Error messages and stack traces - Sample code reproducing the issue - Debug logs if available