https://www.sensoray.com/wiki/index.php?title=2253&feed=atom&action=history
2253 - Revision history
2024-03-28T12:35:48Z
Revision history for this page on the wiki
MediaWiki 1.20.4
https://www.sensoray.com/wiki/index.php?title=2253&diff=1950&oldid=prev
JL: /* Troubleshooting LEDs */
2022-03-10T15:48:15Z
<p><span dir="auto"><span class="autocomment">Troubleshooting LEDs</span></span></p>
<table class='diff diff-contentalign-left'>
<col class='diff-marker' />
<col class='diff-content' />
<col class='diff-marker' />
<col class='diff-content' />
<tr style='vertical-align: top;'>
<td colspan='2' style="background-color: white; color:black;">← Older revision</td>
<td colspan='2' style="background-color: white; color:black;">Revision as of 15:48, 10 March 2022</td>
</tr><tr><td colspan="2" class="diff-lineno">Line 210:</td>
<td colspan="2" class="diff-lineno">Line 210:</td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>{| class="wikitable"</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>{| class="wikitable"</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div>! D1<del class="diffchange diffchange-inline">(</del>green<del class="diffchange diffchange-inline">) </del>|| D2<del class="diffchange diffchange-inline">(</del>red<del class="diffchange diffchange-inline">) </del>|| D3<del class="diffchange diffchange-inline">(</del>amber<del class="diffchange diffchange-inline">) </del>|| <del class="diffchange diffchange-inline">status</del></div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div>! D1<ins class="diffchange diffchange-inline"><br></ins>green || D2<ins class="diffchange diffchange-inline"><br></ins>red || D3<ins class="diffchange diffchange-inline"><br></ins>amber || <ins class="diffchange diffchange-inline">Status</ins></div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>|-</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>|-</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>| on || || || board has power</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>| on || || || board has power</div></td></tr>
</table>
JL
https://www.sensoray.com/wiki/index.php?title=2253&diff=1949&oldid=prev
JL: /* Monochrome Overlay on Device with C++ */
2022-03-10T15:45:39Z
<p><span dir="auto"><span class="autocomment">Monochrome Overlay on Device with C++</span></span></p>
<table class='diff diff-contentalign-left'>
<col class='diff-marker' />
<col class='diff-content' />
<col class='diff-marker' />
<col class='diff-content' />
<tr style='vertical-align: top;'>
<td colspan='2' style="background-color: white; color:black;">← Older revision</td>
<td colspan='2' style="background-color: white; color:black;">Revision as of 15:45, 10 March 2022</td>
</tr><tr><td colspan="2" class="diff-lineno">Line 186:</td>
<td colspan="2" class="diff-lineno">Line 186:</td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>This example shows how to do overlay type #3 listed above.  The overlay will appear in recorded files, snapshots, and the composite video output.</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>This example shows how to do overlay type #3 listed above.  The overlay will appear in recorded files, snapshots, and the composite video output.</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">    </del>{</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>{</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">        </del>MID2253_OSD_DATA osd;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>MID2253_OSD_DATA osd;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">        </del>FILE *fin;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>FILE *fin;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">        </del>unsigned char *pdata;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>unsigned char *pdata;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">        </del>size_t rsize;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>size_t rsize;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">        </del>osd.osdbmp.id = 0;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>osd.osdbmp.id = 0;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">        </del>osd.osdbmp.osdOn = 1;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>osd.osdbmp.osdOn = 1;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">        </del>osd.osdbmp.osdChan = 3;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>osd.osdbmp.osdChan = 3;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">        </del>osd.osdbmp.xoffset = 200;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>osd.osdbmp.xoffset = 200;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">        </del>osd.osdbmp.yoffset = 300;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>osd.osdbmp.yoffset = 300;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">        </del>fin = fopen("logo.bmp", "rb");</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>fin = fopen("logo.bmp", "rb");</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">        </del>pdata = (unsigned char *) malloc(50*1024);</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>pdata = (unsigned char *) malloc(50 * 1024);</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">        </del>rsize = fread(pdata, 1, 50*1024, fin);</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>rsize = fread(pdata, 1, 50*1024, fin);</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">        </del>osd.osdbmp.bmp = pdata;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>osd.osdbmp.bmp = pdata;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">        </del>S2253_SetOsd(MID2253_OSDTYPE_BMP, &osd, 0, 0);</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>S2253_SetOsd(MID2253_OSDTYPE_BMP, &osd, 0, 0);</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">        </del>free(pdata);</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>free(pdata);</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">        </del>fclose(fin);</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>fclose(fin);</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">    </del>}</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>}</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div> </div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">'''</ins>Note:<ins class="diffchange diffchange-inline">''' </ins>Above code is for demonstration purposes only. Please add error checking to production code.</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div>Note: Above code is for demonstration purposes only. <del class="diffchange diffchange-inline"> </del>Please add error checking to production code.</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div></div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>== Troubleshooting LEDs ==</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>== Troubleshooting LEDs ==</div></td></tr>
</table>
JL
https://www.sensoray.com/wiki/index.php?title=2253&diff=1948&oldid=prev
JL: /* Installation Prerequisites for CentOS/Fedora */
2022-03-10T15:43:27Z
<p><span dir="auto"><span class="autocomment">Installation Prerequisites for CentOS/Fedora</span></span></p>
<table class='diff diff-contentalign-left'>
<col class='diff-marker' />
<col class='diff-content' />
<col class='diff-marker' />
<col class='diff-content' />
<tr style='vertical-align: top;'>
<td colspan='2' style="background-color: white; color:black;">← Older revision</td>
<td colspan='2' style="background-color: white; color:black;">Revision as of 15:43, 10 March 2022</td>
</tr><tr><td colspan="2" class="diff-lineno">Line 6:</td>
<td colspan="2" class="diff-lineno">Line 6:</td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>   sudo yum install kernel-devel ImageMagick-devel</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>   sudo yum install kernel-devel ImageMagick-devel</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del style="color: red; font-weight: bold; text-decoration: none;"></del></div></td><td colspan="2"> </td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>== Cross-compiling Linux driver for ARM ==</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>== Cross-compiling Linux driver for ARM ==</div></td></tr>
</table>
JL
https://www.sensoray.com/wiki/index.php?title=2253&diff=1947&oldid=prev
JL: /* Solving devices with serial number 0 */
2022-03-10T15:43:15Z
<p><span dir="auto"><span class="autocomment">Solving devices with serial number 0</span></span></p>
<table class='diff diff-contentalign-left'>
<col class='diff-marker' />
<col class='diff-content' />
<col class='diff-marker' />
<col class='diff-content' />
<tr style='vertical-align: top;'>
<td colspan='2' style="background-color: white; color:black;">← Older revision</td>
<td colspan='2' style="background-color: white; color:black;">Revision as of 15:43, 10 March 2022</td>
</tr><tr><td colspan="2" class="diff-lineno">Line 1:</td>
<td colspan="2" class="diff-lineno">Line 1:</td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>== Solving devices with serial number 0 ==</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>== Solving devices with serial number 0 ==</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div>[[Windows10Privacy|Turn on Windows 10 app access for camera and microphone]]</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">See </ins>[[Windows10Privacy|Turn on Windows 10 app access for camera and microphone]]<ins class="diffchange diffchange-inline">.</ins></div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div> </div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div></div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>== Installation Prerequisites for CentOS/Fedora ==</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>== Installation Prerequisites for CentOS/Fedora ==</div></td></tr>
</table>
JL
https://www.sensoray.com/wiki/index.php?title=2253&diff=1946&oldid=prev
JL: /* Connecting to USB 3.0 ports on Linux */
2022-03-10T15:42:26Z
<p><span dir="auto"><span class="autocomment">Connecting to USB 3.0 ports on Linux</span></span></p>
<table class='diff diff-contentalign-left'>
<col class='diff-marker' />
<col class='diff-content' />
<col class='diff-marker' />
<col class='diff-content' />
<tr style='vertical-align: top;'>
<td colspan='2' style="background-color: white; color:black;">← Older revision</td>
<td colspan='2' style="background-color: white; color:black;">Revision as of 15:42, 10 March 2022</td>
</tr><tr><td colspan="2" class="diff-lineno">Line 31:</td>
<td colspan="2" class="diff-lineno">Line 31:</td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>   [  378.488958] usb 9-1: device descriptor read/8, error -75</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>   [  378.488958] usb 9-1: device descriptor read/8, error -75</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div>Reconnect the device to a USB 2.0 port, or contact support@sensoray.com for RMA. <del class="diffchange diffchange-inline"> </del>Boards manufactured after April 2013 have corrected this issue. <del class="diffchange diffchange-inline"> </del>(Windows is not affected.)</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div>Reconnect the device to a USB 2.0 port, or contact support@sensoray.com for RMA. Boards manufactured after April 2013 have corrected this issue. (Windows is not affected.)</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div> </div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div></div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>== Overlays ==</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>== Overlays ==</div></td></tr>
</table>
JL
https://www.sensoray.com/wiki/index.php?title=2253&diff=1945&oldid=prev
JL: /* Overlay Specifications */
2022-03-10T15:42:00Z
<p><span dir="auto"><span class="autocomment">Overlay Specifications</span></span></p>
<table class='diff diff-contentalign-left'>
<col class='diff-marker' />
<col class='diff-content' />
<col class='diff-marker' />
<col class='diff-content' />
<tr style='vertical-align: top;'>
<td colspan='2' style="background-color: white; color:black;">← Older revision</td>
<td colspan='2' style="background-color: white; color:black;">Revision as of 15:42, 10 March 2022</td>
</tr><tr><td colspan="2" class="diff-lineno">Line 53:</td>
<td colspan="2" class="diff-lineno">Line 53:</td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>One line of text for each video stream (A, B, Output) up to 160 characters, and may include newline (^n) or date (^d) or time (^t) codes inserted.</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>One line of text for each video stream (A, B, Output) up to 160 characters, and may include newline (^n) or date (^d) or time (^t) codes inserted.</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div>For styled text, there are 16 overlay regions for Stream A and B, and 255 regions for Output Stream.  Bitmaps or PNG images can only be used on the Output Stream.  The overlay resolution is not directly limited, but the decoding of the PNG image takes time, and transferring large BMP images over USB and then decoding takes time.  For the Output Stream, the overlay image is applied to a masking buffer once and the output video is rendered in hardware.  For the Encoded Streams, the overlay image must be rendered in software for every frame, and too many or too large overlays can cause video frames to be dropped.  </div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div>For styled text, there are 16 overlay regions for Stream A and B, and 255 regions for Output Stream.  Bitmaps or PNG images can only be used on the Output Stream.  The overlay resolution is not directly limited, but the decoding of the PNG image takes time, and transferring large BMP images over USB and then decoding takes time.  For the Output Stream, the overlay image is applied to a masking buffer once and the output video is rendered in hardware.  For the Encoded Streams, the overlay image must be rendered in software for every frame, and too many or too large overlays can cause video frames to be dropped.</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div> </div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div></div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>== Example for Preview Bitmap Drawing in C# ==</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>== Example for Preview Bitmap Drawing in C# ==</div></td></tr>
</table>
JL
https://www.sensoray.com/wiki/index.php?title=2253&diff=1944&oldid=prev
JL: /* Example for Preview Bitmap Drawing in C# */ fmt src
2022-03-10T15:41:19Z
<p><span dir="auto"><span class="autocomment">Example for Preview Bitmap Drawing in C#: </span> fmt src</span></p>
<table class='diff diff-contentalign-left'>
<col class='diff-marker' />
<col class='diff-content' />
<col class='diff-marker' />
<col class='diff-content' />
<tr style='vertical-align: top;'>
<td colspan='2' style="background-color: white; color:black;">← Older revision</td>
<td colspan='2' style="background-color: white; color:black;">Revision as of 15:41, 10 March 2022</td>
</tr><tr><td colspan="2" class="diff-lineno">Line 64:</td>
<td colspan="2" class="diff-lineno">Line 64:</td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>Below is sample code to draw a Bitmap to the video preview in C#:</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>Below is sample code to draw a Bitmap to the video preview in C#:</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>Bitmap mybmp = new Bitmap(100, 100);</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>Bitmap mybmp = new Bitmap(100, 100);</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>S2253.NORMALIZEDRECT nRect;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>S2253.NORMALIZEDRECT nRect;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>int retVal;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>int retVal;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>S2253.RECTANGLE sRect;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>S2253.RECTANGLE sRect;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>sRect.left = 0;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>sRect.left = 0;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>sRect.top = 0;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>sRect.top = 0;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>sRect.right = mybmp.Width;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>sRect.right = mybmp.Width;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>sRect.bottom = mybmp.Height;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>sRect.bottom = mybmp.Height;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>Graphics myGraphics = Graphics.FromImage(mybmp);</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>Graphics myGraphics = Graphics.FromImage(mybmp);</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>              </div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>              </div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>myGraphics.DrawLine(new Pen(Color.Green, 5.0f), new Point(0, 0), new Point(50, 50));</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>myGraphics.DrawLine(new Pen(Color.Green, 5.0f), new Point(0, 0), new Point(50, 50));</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>nRect.bottom = 0.9f;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>nRect.bottom = 0.9f;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>nRect.top = 0.1f;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>nRect.top = 0.1f;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>nRect.left = 0.1f;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>nRect.left = 0.1f;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>nRect.right = 0.9f;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>nRect.right = 0.9f;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>IntPtr hdcBMP = myGraphics.GetHdc();</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>IntPtr hdcBMP = myGraphics.GetHdc();</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>S2253.SelectObject(hdcBMP, mybmp.GetHbitmap());</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>S2253.SelectObject(hdcBMP, mybmp.GetHbitmap());</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>retVal = S2253.DrawBitmap(hdcBMP, ref sRect, ref nRect, 0.5f, 0, 0);</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>retVal = S2253.DrawBitmap(hdcBMP, ref sRect, ref nRect, 0.5f, 0, 0);</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>myGraphics.ReleaseHdc();</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>myGraphics.ReleaseHdc();</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>In mid2253.cs, define the following if it does not already exist:</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>In mid2253.cs, define the following if it does not already exist:</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">        </del>public struct RECTANGLE</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>public struct RECTANGLE {</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">        </del>{</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">    </ins>public Int32 left;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>public Int32 left;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">    </ins>public Int32 top;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>public Int32 top;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">    </ins>public Int32 right;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>public Int32 right;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">    </ins>public Int32 bottom;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>public Int32 bottom;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>};</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">        </del>};</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>public struct NORMALIZEDRECT {</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">        </del>public struct NORMALIZEDRECT {</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">    </ins>public float left;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>public float left;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">    </ins>public float top;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>public float top;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">    </ins>public float right;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>public float right;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">    </ins>public float bottom;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>public float bottom;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>};</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">        </del>};</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div></div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">        </del>public static Int32 DrawBitmap(IntPtr hdcBMP, ref RECTANGLE src,</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>public static Int32 DrawBitmap(IntPtr hdcBMP, ref RECTANGLE src,</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">                                        </del>ref NORMALIZEDRECT dst, float alpha, int devid, int strmid) {</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">                      </ins>ref NORMALIZEDRECT dst, float alpha, int devid, int strmid)</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>int retVal;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>{</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>retVal = S2253_DrawBitmap(hdcBMP, ref src, ref dst, alpha, devid, strmid);</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>int retVal;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>return retVal;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>retVal = S2253_DrawBitmap(hdcBMP, ref src, ref dst, alpha, devid, strmid);</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">        </del>}</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>return retVal;</div></td></tr>
<tr><td colspan="2"> </td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>}</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">        </del>public static Int32 DrawBitmapColorRef(IntPtr hdcBMP, ref RECTANGLE src,</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>public static Int32 DrawBitmapColorRef(IntPtr hdcBMP, ref RECTANGLE src,</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">                                        </del>ref NORMALIZEDRECT dst, float alpha, UInt32 clrSrcKey, int devid, int strmid) {</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">                      </ins>ref NORMALIZEDRECT dst, float alpha, UInt32 clrSrcKey, int devid, int strmid)</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>int retVal;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>{</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>retVal = S2253_DrawBitmapColorRef(hdcBMP, ref src, ref dst, alpha, clrSrcKey, devid, strmid);</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>int retVal;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>return retVal;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>retVal = S2253_DrawBitmapColorRef(hdcBMP, ref src, ref dst, alpha, clrSrcKey, devid, strmid);</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">        </del>}</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>return retVal;</div></td></tr>
<tr><td colspan="2"> </td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>}</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">        </del>[DllImport("mid2253.dll", CallingConvention = CallingConvention.StdCall, SetLastError = true)]</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>[DllImport("mid2253.dll", CallingConvention = CallingConvention.StdCall, SetLastError = true)]</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">        </del>static extern Int32 S2253_DrawBitmap(IntPtr hdcBMP, ref RECTANGLE src, ref NORMALIZEDRECT dst,</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>static extern Int32 S2253_DrawBitmap(IntPtr hdcBMP, ref RECTANGLE src, ref NORMALIZEDRECT dst, <ins class="diffchange diffchange-inline">_</ins></div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>                                         float alpha, int devid, int strmidx);</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>                                         float alpha, int devid, int strmidx);</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">        </del>[DllImport("mid2253.dll", CallingConvention = CallingConvention.StdCall, SetLastError = true)]</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>[DllImport("mid2253.dll", CallingConvention = CallingConvention.StdCall, SetLastError = true)]</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">        </del>static extern Int32 S2253_DrawBitmapColorRef(IntPtr hdcBMP, ref RECTANGLE src, ref NORMALIZEDRECT dst,</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>static extern Int32 S2253_DrawBitmapColorRef(IntPtr hdcBMP, ref RECTANGLE src, ref NORMALIZEDRECT dst, <ins class="diffchange diffchange-inline">_</ins></div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>                                         float alpha, UInt32 clrSrcKey, int devid, int strmidx);</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>                                         float alpha, UInt32 clrSrcKey, int devid, int strmidx);</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">        </del>[DllImport("gdi32.dll", EntryPoint = "SelectObject", CallingConvention = CallingConvention.Cdecl)]</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>[DllImport("gdi32.dll", EntryPoint = "SelectObject", CallingConvention = CallingConvention.Cdecl)]</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">        </del>public static extern IntPtr SelectObject(IntPtr hdc, IntPtr h);</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline"> </ins>public static extern IntPtr SelectObject(IntPtr hdc, IntPtr h);</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>== Monochrome Overlay on Device with C# ==</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>== Monochrome Overlay on Device with C# ==</div></td></tr>
</table>
JL
https://www.sensoray.com/wiki/index.php?title=2253&diff=1943&oldid=prev
JL: /* Monochrome Overlay on Device with C# */ fmt src
2022-03-10T15:34:56Z
<p><span dir="auto"><span class="autocomment">Monochrome Overlay on Device with C#: </span> fmt src</span></p>
<table class='diff diff-contentalign-left'>
<col class='diff-marker' />
<col class='diff-content' />
<col class='diff-marker' />
<col class='diff-content' />
<tr style='vertical-align: top;'>
<td colspan='2' style="background-color: white; color:black;">← Older revision</td>
<td colspan='2' style="background-color: white; color:black;">Revision as of 15:34, 10 March 2022</td>
</tr><tr><td colspan="2" class="diff-lineno">Line 133:</td>
<td colspan="2" class="diff-lineno">Line 133:</td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>  public struct MID2253_OSD_BMP</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>  public struct MID2253_OSD_BMP</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>  {</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>  {</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div>   public int osdOn; <del class="diffchange diffchange-inline">              </del>// OSD on if != 0</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div>   public int osdOn; <ins class="diffchange diffchange-inline">    </ins>// OSD on if != 0</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div>   public int osdChan; <del class="diffchange diffchange-inline">      </del>// osd channel to update<del class="diffchange diffchange-inline">.  osdChan</del>=<del class="diffchange diffchange-inline">0 for </del>stream A<del class="diffchange diffchange-inline">, osdChan</del>=<del class="diffchange diffchange-inline">1 for </del>stream B, <del class="diffchange diffchange-inline">osdChan</del>=<del class="diffchange diffchange-inline">2 for </del>output, <del class="diffchange diffchange-inline"> osdChan</del>=<del class="diffchange diffchange-inline">3 for </del>both streams</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div>   public int osdChan; <ins class="diffchange diffchange-inline">  </ins>// osd channel to update<ins class="diffchange diffchange-inline">: 0 </ins>= stream A<ins class="diffchange diffchange-inline">; 1 </ins>= stream B, <ins class="diffchange diffchange-inline">2 </ins>= output, <ins class="diffchange diffchange-inline">3 </ins>= both streams</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div>   public int id; <del class="diffchange diffchange-inline">              </del>// region id: 0..15</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div>   public int id; <ins class="diffchange diffchange-inline">      </ins>// region id: 0..15</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div>   public int xoffset; <del class="diffchange diffchange-inline">      </del>// x offset: relative to left</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div>   public int xoffset; <ins class="diffchange diffchange-inline">  </ins>// x offset: relative to left</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div>   public int yoffset; <del class="diffchange diffchange-inline">      </del>// y offset: relative to top</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div>   public int yoffset; <ins class="diffchange diffchange-inline">  </ins>// y offset: relative to top</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div>   public IntPtr bmp; <del class="diffchange diffchange-inline">              </del>// pointer to bitmap image data (as loaded from file)</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div>   public IntPtr bmp; <ins class="diffchange diffchange-inline">  </ins>// pointer to bitmap image data (as loaded from file)</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>  };</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>  };</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del style="color: red; font-weight: bold; text-decoration: none;"></del></div></td><td colspan="2"> </td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>Add the following to mid2253.cs:</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>Add the following to mid2253.cs:</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div>  public static Int32 SetOsd( ref MID2253_OSD_BMP osd, Int32 devid, Int32 strmidx )</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div>  public static Int32 SetOsd(ref MID2253_OSD_BMP osd, Int32 devid, Int32 strmidx)</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>  {</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>  {</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>   int hr;</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>   int hr;</div></td></tr>
<tr><td colspan="2" class="diff-lineno">Line 155:</td>
<td colspan="2" class="diff-lineno">Line 154:</td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>   r.bmp = osd.bmp;</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>   r.bmp = osd.bmp;</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>   </div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>   </div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div>   hr = S2253_SetOsd( MID2253_OSDTYPE.MID2253_OSDTYPE_BMP, ref r, devid, strmidx );</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div>   hr = S2253_SetOsd(MID2253_OSDTYPE.MID2253_OSDTYPE_BMP, ref r, devid, strmidx);</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>   return hr;</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>   return hr;</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>  }</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>  }</div></td></tr>
<tr><td colspan="2" class="diff-lineno">Line 161:</td>
<td colspan="2" class="diff-lineno">Line 160:</td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>Example code for C# Form loading bitmap from file:</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>Example code for C# Form loading bitmap from file:</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>  {</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>  {</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>int brd_idx = 0;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>int brd_idx = 0;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>int streamIdx = 0;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>int streamIdx = 0;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>MemoryStream strm = new MemoryStream();</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>MemoryStream strm = new MemoryStream();</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>S2253.MID2253_OSD_BMP osdBmp = new S2253.MID2253_OSD_BMP();</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>S2253.MID2253_OSD_BMP osdBmp = new S2253.MID2253_OSD_BMP();</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>ImageConverter converter = new ImageConverter();</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>ImageConverter converter = new ImageConverter();</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>Bitmap mybmp = (Bitmap) Bitmap.FromFile("Logo.bmp");</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>Bitmap mybmp = (Bitmap) Bitmap.FromFile("Logo.bmp");</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>byte[] bmpByteArray = new byte[0];</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>byte[] bmpByteArray = new byte[0];</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>using (strm) {</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>using (strm) {</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">                </del>mybmp.Save(strm, System.Drawing.Imaging.ImageFormat.Bmp);</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">    </ins>mybmp.Save(strm, System.Drawing.Imaging.ImageFormat.Bmp);</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">                </del>strm.Close();</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">    </ins>strm.Close();</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">                </del>bmpByteArray = strm.ToArray();</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">    </ins>bmpByteArray = strm.ToArray();</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>}</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>}</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>              </div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>              </div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>GCHandle pinnedArray = GCHandle.Alloc(bmpByteArray, GCHandleType.Pinned);</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>GCHandle pinnedArray = GCHandle.Alloc(bmpByteArray, GCHandleType.Pinned);</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>IntPtr ptr = pinnedArray.AddrOfPinnedObject();</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>IntPtr ptr = pinnedArray.AddrOfPinnedObject();</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>osdBmp.bmp = ptr;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>osdBmp.bmp = ptr;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>osdBmp.id = 1;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>osdBmp.id = 1;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>osdBmp.osdChan = 3;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>osdBmp.osdChan = 3;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>osdBmp.osdOn = 1;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>osdBmp.osdOn = 1;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>osdBmp.xoffset = 50;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>osdBmp.xoffset = 50;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>osdBmp.yoffset = 50;</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>osdBmp.yoffset = 50;</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>int retVal = S2253.SetOsd(ref osdBmp, brd_idx, streamIdx);</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>int retVal = S2253.SetOsd(ref osdBmp, brd_idx, streamIdx);</div></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div><del class="diffchange diffchange-inline">            </del>pinnedArray.Free();</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins class="diffchange diffchange-inline">  </ins>pinnedArray.Free();</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>  }</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>  }</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td></tr>
</table>
JL
https://www.sensoray.com/wiki/index.php?title=2253&diff=1445&oldid=prev
Admin: /* Troubleshooting LEDs */
2020-06-04T17:01:53Z
<p><span dir="auto"><span class="autocomment">Troubleshooting LEDs</span></span></p>
<table class='diff diff-contentalign-left'>
<col class='diff-marker' />
<col class='diff-content' />
<col class='diff-marker' />
<col class='diff-content' />
<tr style='vertical-align: top;'>
<td colspan='2' style="background-color: white; color:black;">← Older revision</td>
<td colspan='2' style="background-color: white; color:black;">Revision as of 17:01, 4 June 2020</td>
</tr><tr><td colspan="2" class="diff-lineno">Line 230:</td>
<td colspan="2" class="diff-lineno">Line 230:</td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td></tr>
<tr><td class='diff-marker'>−</td><td style="background: #ffa; color:black; font-size: smaller;"><div>[[Category:<del class="diffchange diffchange-inline">Products</del>]]</div></td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div>[[Category:<ins class="diffchange diffchange-inline">2253| </ins>]]</div></td></tr>
</table>
Admin
https://www.sensoray.com/wiki/index.php?title=2253&diff=1200&oldid=prev
PE at 23:48, 8 June 2018
2018-06-08T23:48:24Z
<p></p>
<table class='diff diff-contentalign-left'>
<col class='diff-marker' />
<col class='diff-content' />
<col class='diff-marker' />
<col class='diff-content' />
<tr style='vertical-align: top;'>
<td colspan='2' style="background-color: white; color:black;">← Older revision</td>
<td colspan='2' style="background-color: white; color:black;">Revision as of 23:48, 8 June 2018</td>
</tr><tr><td colspan="2" class="diff-lineno">Line 1:</td>
<td colspan="2" class="diff-lineno">Line 1:</td></tr>
<tr><td colspan="2"> </td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins style="color: red; font-weight: bold; text-decoration: none;">== Solving devices with serial number 0 ==</ins></div></td></tr>
<tr><td colspan="2"> </td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins style="color: red; font-weight: bold; text-decoration: none;"></ins></div></td></tr>
<tr><td colspan="2"> </td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins style="color: red; font-weight: bold; text-decoration: none;">[[Windows10Privacy|Turn on Windows 10 app access for camera and microphone]]</ins></div></td></tr>
<tr><td colspan="2"> </td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins style="color: red; font-weight: bold; text-decoration: none;"></ins></div></td></tr>
<tr><td colspan="2"> </td><td class='diff-marker'>+</td><td style="background: #cfc; color:black; font-size: smaller;"><div><ins style="color: red; font-weight: bold; text-decoration: none;"></ins></div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>== Installation Prerequisites for CentOS/Fedora ==</div></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"><div>== Installation Prerequisites for CentOS/Fedora ==</div></td></tr>
<tr><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td><td class='diff-marker'> </td><td style="background: #eee; color:black; font-size: smaller;"></td></tr>
</table>
PE