- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
how can we display fx2lp data(imge data) in the control center(or streamer) using direct x and direct show method?
anybody have done it?please let me know.
cypress has any code snipet regarding this host application?
thanks.
geetha
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello Geethanjali,
Cypress does not provide a ready application that uses the Direct Show APIs to display image on the UI.
The below code snippet can be used to convert raw data into bitmap format that can be displayed on a Picture Box in Windows Forms Applications.
{
Bitmap bitmap = new Bitmap(width, height, System.Drawing.Imaging.PixelFormat.Format8bppIndexed);
BitmapData bitmapData = bitmap.LockBits(new Rectangle(0, 0, width, height), ImageLockMode.WriteOnly, bitmap.PixelFormat);
Marshal.Copy(read_data, 0, bitmapData.Scan0, read_data.Length);
bitmap.UnlockBits(bitmapData);
pictureBox1.Image = bitmap;
}
Best regards,
Srinath S
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello Geethanjali,
Cypress does not provide a ready application that uses the Direct Show APIs to display image on the UI.
The below code snippet can be used to convert raw data into bitmap format that can be displayed on a Picture Box in Windows Forms Applications.
{
Bitmap bitmap = new Bitmap(width, height, System.Drawing.Imaging.PixelFormat.Format8bppIndexed);
BitmapData bitmapData = bitmap.LockBits(new Rectangle(0, 0, width, height), ImageLockMode.WriteOnly, bitmap.PixelFormat);
Marshal.Copy(read_data, 0, bitmapData.Scan0, read_data.Length);
bitmap.UnlockBits(bitmapData);
pictureBox1.Image = bitmap;
}
Best regards,
Srinath S
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
thanks for giving reply about Direct X, Direct show , and can you just tell some what clearly about bitmap generation which you sent above ,for that how we have to give input directly from buffer without writing it int file .
Best regards
Geetanjali T D
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello Geethanjali,
Yes, the buffer that is used to read data from the FX2LP is passed as an input to this function block. I have named it as 'read_data'.
Best regards,
Srinath S