# Using Bitmap in controls GUI

**URL:** <https://iplug2.discourse.group/t/using-bitmap-in-controls-gui/131>\
**Category:** macOS\
**Created:** [24 June 2020 11:04 UTC](https://iplug2.discourse.group/t/using-bitmap-in-controls-gui/131 "2020-06-24T11:04:58Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Alex](https://yyz2.discourse-cdn.com/free1/user_avatar/iplug2.discourse.group/alex/32/72_2.png) [@Alex](https://iplug2.discourse.group/u/Alex)\
**Post date:** [24 June 2020 11:04 UTC](https://iplug2.discourse.group/t/using-bitmap-in-controls-gui/131/1 "2020-06-24T11:04:58Z")

</div>

How can I use bmp images in the controls? Where can I see examples or read about it?

Is it the correct way to set the background as  
pGraphics-\>AttachBackground(“resources/bkgr\_newgui9.bmp”);  
Does it load the file dynamically? Or is it use the resource (as vstgui) .

And attaching of a knob to the background should be done as  
pGraphics-\>AttachControl(new IBKnobControl()) ? I need some glue on this as IPlug2 examples seem to use VG only, and working with bmp was intuitive in WDL-OL .  
Thanks!

---

<div class="post-metadata">

**Author:** ![olilarkin](https://yyz2.discourse-cdn.com/free1/user_avatar/iplug2.discourse.group/olilarkin/32/2_2.png) [@olilarkin](https://iplug2.discourse.group/u/olilarkin)\
**Post date:** [24 June 2020 11:06 UTC](https://iplug2.discourse.group/t/using-bitmap-in-controls-gui/131/2 "2020-06-24T11:06:35Z")

</div>

see e.g. IPlugControls example

also the Wiki:

> **[iPlug2/iPlug2](https://github.com/iPlug2/iPlug2/wiki/06_Load_a_resource)**
>
> C++ Audio Plug-in Framework for desktop, mobile and web \[PRE-RELEASE\] - iPlug2/iPlug2
