GFilter.cpp File Reference

Graphics file filters. More...

#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <math.h>
#include "Gdc2.h"
#include "GString.h"
#include "GVariant.h"


class  GdcBmp
 Windows and OS/2 BMP file filter. More...


GSurfaceLoadDC (char *Name, bool UseOSLoader)
 Loads a image from a file.
bool WriteDC (char *Name, GSurface *pDC)
 Writes an image to a file.

Detailed Description

Graphics file filters.

Matthew Allen

Function Documentation

GSurface* LoadDC ( char *  Name,
bool  UseOSLoader = true 

Loads a image from a file.

This function uses the compiled in codecs, some of which require external shared libraries / DLL's to function. Other just need the right source to be compiled in.

Lgi comes with the following image codecs:

  • Windows or OS/2 Bitmap: GdcBmp (GFilter.cpp)
  • PCX: GdcPcx (Pcx.cpp)
  • GIF: GdcGif (Gif.cpp and Lzw.cpp)
  • JPEG: GdcJpeg (Jpeg.cpp + libjpeg library)
  • PNG: GdcPng (Png.cpp + libpng library)
Name  The full path of the file
UseOSLoader  [Optional] Enable OS based loaders

References GdcRGB::B, FILTER_CAP_READ, GdcRGB::G, GDC_OR, GDC_PROMOTE_ON_LOAD, GDC_SET, LgiSleep, GFile::Open(), GdcRGB::R, GFile::Read(), Rgb15, GFile::SetPos(), and GVariant::WStr().

Referenced by GBitmap::GBitmap(), GDefaultDocumentEnv::GetContent(), LgiLoadImageList(), GTrayIcon::Load(), and GToolBar::SetBitmap().

Generated on Wed Dec 1 15:41:00 2010 for Lgi by  doxygen