DisplayBitmap
A bitmap resource that can be used by the display pipeline (currently only in OpenGL display). Reuse DisplayBitmaps for drawing if possible; it is much more expensive to construct new DisplayBitmaps than it is to reuse existing DisplayBitmaps.
Inheritance Hierarchy
System.Object
Rhino.Display.DisplayBitmap
Namespace: Rhino.Display
Assembly: RhinoCommon (in RhinoCommon.dll)
Syntax
public class DisplayBitmap : IDisposable
The DisplayBitmap type exposes the following members.
Constructors
Name
Description
Public Method
DisplayBitmap(Bitmap)
Constructs a DisplayBitmap from an existing bitmap.
Public Method
DisplayBitmap(String, Bitmap)
Creates a DisplayBitmap either from a path, or a bitmap. If the path is null, a random tag name will be used. If the bitmap is null, the bitmap will be loaded from the path. If both are null, the object is invalid. if both are valid objects, the bitmap will be used and it will be added to Rhino’s bitmap cache with the path supplied. In other words, this is a way to add a bitmap from memory directly into Rhino’s memory cache.
Properties
Name
Description
Public Property
Size
Size of the underlying bitmap image
Methods
Name
Description
Public Method
Dispose.
Actively reclaims unmanaged resources that this instance uses.
Protected Method
Dispose(Boolean)
For derived class implementers.
This method is called with argument true when class user calls Dispose(), while with argument false when the Garbage Collector invokes the finalizer, or Finalize() method.
You must reclaim all used unmanaged resources in both cases, and can use this chance to call Dispose on disposable fields if the argument is true.
Also, you must call the base virtual method within your overriding method.
Public Method
Equals
Determines whether the specified object is equal to the current object.
(Inherited from Object.)
Protected Method
Finalize
Passively reclaims unmanaged resources when the class user did not explicitly call Dispose().
(Overrides Object.Finalize..)
Public Method
GetBlendModes
Gets the source and destination blend modes.
Public Method
GetHashCode
Serves as the default hash function.
(Inherited from Object.)
Public Method
GetType
Gets the Type of the current instance.
(Inherited from Object.)
Public Method
Static Member
Load
Load a DisplayBitmap from and image file on disk or from URL. If path starts with http:// or https:// then an attempt is made to load the bitmap from an online resource
Protected Method
MemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Public Method
SetBlendFunction
Sets blending function used to determine how this bitmap is blended with the current frame buffer color. The default setting is SourceAlpha for source and OneMinusSourceAlpha for destination. See OpenGL’s glBlendFunc for details.
http://www.opengl.org/sdk/docs/man/xhtml/glBlendFunc.xml
Public Method
ToString
Returns a string that represents the current object.
(Inherited from Object.)