VizEx View iOS

The distribution of technical documentation on tablet devices is becoming very important. The ability to deploy CGM files on iOS is now possible with this Larson product. VizEx View iOS enables delivery of quality native CGM graphics including all the functionality you would expect on other platforms.

VizEx View iOS is a Library for viewing and interacting with CGM files. A Static Library that can by embedded and utilized in Object C or C++ (Swift) based application.

Include source code example for implementing a basic CGM viewer application on iOS and receive touch events for manipulation of a CGM view. Also includes example of how to embed in web based (WebKit ) application,

Code Sample:

-(void)drawRect:(CGRect)rect
{
  CGContextRef context = UIGraphicsGetCurrentContext();

  // assumes m_pDrawQuartz has been initialzed to CDrawQuartz class
  // and that m_pCgmObjects points to CGM container with CGM loaded
  m_pDrawQuartz->setDisplay((void*)context);
  m_pDrawQuartz->open();

  DRect clientRect= DRect(0, 0, self.frame.size.width,self.frame.size.height);
  DRect viewport = clientRect;

  double windowAspect = window.Height() / window.Width();
  double viewAspect = viewport.Height() / viewport.Width();

  // center the view
  if (windowAspect > viewAspect)
  {
      double newWidth = viewport.Height() / windowAspect;
      double offset = viewport.Width() - newWidth;
      viewport.left += offset / 2.0;
      viewport.right -= offset / 2.0;
  }
  else
  {
      double newHeight = viewport.Width() * windowAspect;
      double offset = viewport.Height() - newHeight;
      viewport.top += offset / 2.0;
      viewport.bottom -= offset / 2.0;

  }
  m_pDrawQuartz->setTransform(&window, &viewport, &clientRect,
          0, CDrawBase::upperLeft);

  m_pDrawQuartz->clear();
  m_pCgmObjects->Draw(m_pDrawQuartz, drawHotspots);
  }

Platforms: iOS 7 and later 32 and 64 bit
Input: CGM V1-V4, CGM+, TIFF
Profiles: ATA, PIP, S1000D, and WebCGM