No BSD License  

Highlights from
FireWire Vision Tools

  • filterYUVimage(yuv, rgbIn...filter supplied YUV image according to the specified ranges and return
  • isalphanum(instr)
  • rgb2yuv(src)
  • test(varargin) test program to continiously acquire pictures from the camera
  • test(varargin) test program to continiously capture pictures from the camera and process
  • test(varargin) test program to continiously capture pictures from the camera and process
  • test(varargin) test program to continiously capture pictures from the camera and process
  • test(varargin) test program to continiously capture stereoscopic pictures from the
  • test(varargin) test program to continiously capture stereoscopic pictures from the
  • test(varargin) test program for 'imgProc', colour file: 'testcolors.txt'
  • test(varargin) test program for 'imgProcSilent', colour file: 'testcolors.txt'
  • test(varargin) test program for 'imgProcSilent', colour file: 'testcolors.txt'
  • test(varargin) test program to continiously capture stereoscopic pictures from the
  • test(varargin) test program to continiously capture pictures from the camera
  • test(varargin) test program for 'imgProc', colour file: 'testcolors.txt'
  • test(varargin) test program for 'imgProc', colour file: 'testcolors.txt'
  • test(varargin) test program to continiously capture stereoscopic pictures from the
  • test(varargin) test program to continiously capture stereoscopic pictures from the
  • test(varargin) test program to continiously capture pictures from the camera and process
  • test(varargin) test program to continiously capture pictures from the camera and process
  • test(varargin) test program to continiously capture pictures from the camera and
  • test(varargin) test program to continiously capture pictures from the camera and process
  • test(varargin) test program to continiously capture stereoscopic pictures from the
  • test(varargin) test program to continiously capture pictures from the camera and
  • test(varargin) test program to continiously capture pictures from the camera
  • test(varargin) test program to continiously acquire pictures from the camera
  • trainCameraGUI(varargin)TRAINCAMERAGUI M-file for trainCameraGUI.fig
  • yuv2rgb(src)
  • cc.mdetermine driver installation -- assumed to be in folder _CMU1394
  • cc.mdetermine driver installation -- assumed to be in folder _CMU1394
  • cc.mdetermine driver installation -- assumed to be in folder _CMU1394
  • cc.mdetermine driver installation -- assumed to be in folder _CMU1394
  • cc.mdetermine driver installation -- assumed to be in folder _CMU1394
  • cc.mdetermine driver installation -- assumed to be in folder _CMU1394
  • cc.mdetermine driver installation -- assumed to be in folder _CMU1394
  • cc.mdetermine driver installation -- assumed to be in folder _CMU1394
  • cc.mdetermine driver installation -- assumed to be in folder _CMU1394
  • cc.mdetermine driver installation -- assumed to be in folder _CMU1394
  • cc.mdetermine driver installation -- assumed to be in folder _CMU1394
  • cc.mdetermine driver installation -- assumed to be in folder _CMU1394
  • trainCamera.mtraining program... acquires RGB/YUYV image data from a the camera and extracts the colour information of
  • trainCameraStereo.mtraining program... acquires RGB/YUYV image data from a the cameras (stereoscopic vision)
  • trainStill.mtraining program... reads RGB/YUV image data from a mat-file and extracts the colour information of
  • CameraCoordinates
  • CameraCoordinates
  • test_short.avi
  • View all files
image thumbnail

FireWire Vision Tools

by

 

23 May 2008 (Updated )

A simple MATLAB interface to "FireWire Digital Cameras" and the Color Machine Vision algorithms "CMV

rgb2yuv(src)
% converts rgb data to yuv  (FW-04-03)

function dst = rgb2yuv(src)

% ensure this runs with rgb images as well as rgb triples
if(length(size(src)) > 2)
    
    % rgb image ([r] [g] [b])
    r = double(src(:,:,1));
    g = double(src(:,:,2));
    b = double(src(:,:,3));
    
elseif(length(src) == 3)
    
    % rgb triplet ([r, g, b])
    r = double(src(1));
    g = double(src(2));
    b = double(src(3));
    
else
    
    % unknown input format
    error('rgb2yuv: unknown input format');
    
end
    
% convert...
y = floor(0.3*r + 0.5881*g + 0.1118*b);
u = floor(-0.15*r - 0.2941*g + 0.3882*b + 128);
v = floor(0.35*r - 0.2941*g - 0.0559*b + 128);

% ensure valid range for uint8 values
y(y > 255) = 255;
y(y < 0)   = 0;
u(u > 255) = 255;
u(u < 0)   = 0;
v(v > 255) = 255;
v(v < 0)   = 0;


% generate output
if(length(size(src)) > 2)
    
    % yuv image ([y] [u] [v])
    dst(:,:,1) = uint8(y);
    dst(:,:,2) = uint8(u);
    dst(:,:,3) = uint8(v);
    
else
    
    % yuv triplet ([y, u, v])
    dst = uint8([y, u, v]);
    
end

Contact us