synced wxImage,wxBitmap docs with my changes

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@9832 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Václav Slavík
2001-04-21 23:18:05 +00:00
parent 1600865926
commit b06a6b20d5
2 changed files with 44 additions and 18 deletions

View File

@@ -74,6 +74,23 @@ Creates a bitmap from XPM data.
Loads a bitmap from a file or resource.
\func{}{wxBitmap}{\param{const wxImage\&}{ img}, \param{int}{ depth = -1}}
Creates bitmap object from the image. This has to be done
to actually display an image as you cannot draw an image directly on a window.
The resulting bitmap will use the provided colour depth (or that of the
current system if depth is -1) which entails that a colour reduction has
to take place.
When in 8-bit mode (PseudoColour mode), the GTK port will use a color cube created
on program start-up to look up colors. This ensures a very fast conversion, but
the image quality won't be perfect (and could be better for photo images using more
sophisticated dithering algorithms).
On Windows, if there is a palette present (set with SetPalette), it will be used when
creating the wxBitmap (most useful in 8-bit display mode). On other platforms,
the palette is currently ignored.
\wxheading{Parameters}
\docparam{bits}{Specifies an array of pixel values.}
@@ -109,6 +126,8 @@ In addition, wxBitmap can read all formats that \helpref{wxImage}{wximage} can,
wxBITMAP\_TYPE\_JPEG, wxBITMAP\_TYPE\_TIF, wxBITMAP\_TYPE\_PNG, wxBITMAP\_TYPE\_GIF, wxBITMAP\_TYPE\_PCX,
and wxBITMAP\_TYPE\_PNM. Of course, you must have wxImage handlers loaded. }
\docparam{img}{Platform-independent wxImage object.}
\wxheading{Remarks}
The first form constructs a bitmap object with no data; an assignment or another member function such as Create
@@ -207,6 +226,14 @@ Deletes all bitmap handlers.
This function is called by wxWindows on exit.
\membersection{wxBitmap::ConvertToImage}\label{wxbitmapconverttoimage}
\func{wxImage}{ConvertToImage}{\void}
Creates an image from a platform-dependent bitmap. This preserves
mask information so that bitmaps and images can be converted back
and forth without loss in that respect.
\membersection{wxBitmap::Create}\label{wxbitmapcreate}
\func{virtual bool}{Create}{\param{int}{ width}, \param{int}{ height}, \param{int}{ depth = -1}}