Visualization Library 2.0.0-b5

A lightweight C++ OpenGL middleware for 2D/3D graphics

VL     Star     Watch     Fork     Issue

[Download] [Tutorials] [All Classes] [Grouped Classes]
Macros | Functions
rpng-win.c File Reference
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <time.h>
#include <windows.h>
#include <conio.h>
#include "readpng.h"

Go to the source code of this file.

Macros

#define PROGNAME   "rpng-win"
 
#define LONGNAME   "Simple PNG Viewer for Windows"
 
#define VERSION   "2.01 of 16 March 2008"
 
#define alpha_composite(composite, fg, alpha, bg)
 

Functions

LRESULT CALLBACK rpng_win_wndproc (HWND, UINT, WPARAM, LPARAM)
 
int WINAPI WinMain (HINSTANCE hInst, HINSTANCE hPrevInst, PSTR cmd, int showmode)
 

Macro Definition Documentation

◆ alpha_composite

#define alpha_composite (   composite,
  fg,
  alpha,
  bg 
)
Value:
{ \
ush temp = ((ush)(fg)*(ush)(alpha) + \
(ush)(bg)*(ush)(255 - (ush)(alpha)) + (ush)128); \
(composite) = (uch)((temp + (temp >> 8)) >> 8); \
}
unsigned short ush
Definition: zutil.h:36
GLfloat GLfloat GLfloat alpha
unsigned char uch
Definition: zutil.h:34

Definition at line 100 of file rpng-win.c.

◆ LONGNAME

#define LONGNAME   "Simple PNG Viewer for Windows"

Definition at line 80 of file rpng-win.c.

◆ PROGNAME

#define PROGNAME   "rpng-win"

Definition at line 79 of file rpng-win.c.

◆ VERSION

#define VERSION   "2.01 of 16 March 2008"

Definition at line 81 of file rpng-win.c.

Function Documentation

◆ rpng_win_wndproc()

LRESULT CALLBACK rpng_win_wndproc ( HWND  hwnd,
UINT  iMsg,
WPARAM  wP,
LPARAM  lP 
)

Definition at line 644 of file rpng-win.c.

References image_height, and image_width.

◆ WinMain()

int WINAPI WinMain ( HINSTANCE  hInst,
HINSTANCE  hPrevInst,
PSTR  cmd,
int  showmode 
)

Definition at line 140 of file rpng-win.c.

References error, FALSE, msg, and NULL.