• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdelibs API Reference
  • KDE Home
  • Contact Us
 

KImgIO

  • sources
  • kde-4.14
  • kdelibs
  • kimgio
Macros | Functions
pic_write.cpp File Reference
#include "pic_rw.h"
#include <netinet/in.h>
#include <iostream>
#include <qimage.h>
Include dependency graph for pic_write.cpp:

Go to the source code of this file.

Macros

#define FAIL()
 

Functions

unsigned convertABGRtoRGBA (unsigned pixel)
 
static bool encodeRLE (const unsigned *image, unsigned char *output, bool rgb, unsigned max, unsigned &oConsumed, unsigned &oProduced)
 
void pic_write (QIODevice *dev, const QImage *img)
 
static bool writeHeader (QIODevice *dev, std::string msg, unsigned width, unsigned height, bool alpha)
 
static bool writeRow (QIODevice *dev, unsigned *row, unsigned width, bool alpha)
 

Macro Definition Documentation

#define FAIL ( )
Value:
{ \
std::cout << "ERROR Writing PIC!" << std::endl; \
return; \
}

Definition at line 206 of file pic_write.cpp.

Function Documentation

unsigned convertABGRtoRGBA ( unsigned  pixel)
inline

Definition at line 84 of file pic_write.cpp.

static bool encodeRLE ( const unsigned *  image,
unsigned char *  output,
bool  rgb,
unsigned  max,
unsigned &  oConsumed,
unsigned &  oProduced 
)
static

Encodes a portion of the image in RLE coding.

Parameters
imageThe image that we want to encode
outputThe output buffer
channelsThe number of channels to write
offsetOffset in bytes to copy
maxThe maximum number of pixels to write
oConsumedThe number of pixels consumed from image
oProducedThe number of bytes produced in out
Returns
True on success

Definition at line 103 of file pic_write.cpp.

void pic_write ( QIODevice *  dev,
const QImage *  img 
)

Pic write handler for Qt / KDE.

Definition at line 213 of file pic_write.cpp.

static bool writeHeader ( QIODevice *  dev,
std::string  msg,
unsigned  width,
unsigned  height,
bool  alpha 
)
static

PIC_RW - Qt PIC Support Copyright (C) 2007 Ruben Lopez r.lop.nosp@m.ez@b.nosp@m.ren.e.nosp@m.s

This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.

You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software

Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA

Writes the PIC header info.

Parameters
devIO Device
msgHeader message
widthImage width
heightImage height
alphaImage has alpha?
Returns
True on success

Definition at line 42 of file pic_write.cpp.

static bool writeRow ( QIODevice *  dev,
unsigned *  row,
unsigned  width,
bool  alpha 
)
static

Writes a row to the file.

Returns
True on success

Definition at line 168 of file pic_write.cpp.

This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:22:49 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

KImgIO

Skip menu "KImgIO"
  • Main Page
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members
  • Related Pages

kdelibs API Reference

Skip menu "kdelibs API Reference"
  • DNSSD
  • Interfaces
  •   KHexEdit
  •   KMediaPlayer
  •   KSpeech
  •   KTextEditor
  • kconf_update
  • KDE3Support
  •   KUnitTest
  • KDECore
  • KDED
  • KDEsu
  • KDEUI
  • KDEWebKit
  • KDocTools
  • KFile
  • KHTML
  • KImgIO
  • KInit
  • kio
  • KIOSlave
  • KJS
  •   KJS-API
  •   WTF
  • kjsembed
  • KNewStuff
  • KParts
  • KPty
  • Kross
  • KUnitConversion
  • KUtils
  • Nepomuk
  • Plasma
  • Solid
  • Sonnet
  • ThreadWeaver

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal