Click here to Skip to main content
11,582,850 members (75,231 online)
Rate this: bad
good
Please Sign up or sign in to vote.
See more: C++ Windows Win32 DirectX , +
hi every one i made an app that creates a steam using directshow & c++ using win32 components .
i'm able to stop this stream and take picture at any moment it's fine .
the thing is that i need in some way to place a rectangle inside the window render and be able to move this rectangle & resize it
i'm avoiding to develop a filter because it won't give me this functionality
any idea
could directDraw help me in this task !!
Posted 28-Aug-12 6:27am
Comments
Joan Murt at 28-Aug-12 15:18pm
   
It's a pity Jack, not to be able to vote comments. I would vote this one a double 5.
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

You keep rephrasing the question and getting valid answers.

This question is likely to get you similar answers.

What you're asking for is an advanced topic. There are no simple or easy answers.

If you don't want to use filters, you'll have to draw the rectangle on the surface after your other functions draw on the surface. How you do that is going to be dependent on the technologies you use and the way you structure your drawing code.

You're going to have to learn more about graphics programming to proceed further.

It's not a topic we can spoon feed you on.

Look for examples on the web that do similar things. Study the code. Look up documentation on any calls you don't understand. Read tutorials on those topics.

As you learn more, please come back with more specific technical questions.
  Permalink  
Comments
merousoft at 29-Aug-12 4:16am
   
oh thx for this info i just wanted some helping idea but ur answer were clear
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 2

Hello,

Drawing rectangle on a video can be done via few ways:
1. Implementing your own allocator presenter and do render video with your own drawing (Direct3D presenting EVR or VMR).
2. In application create callback via ISampleGrabber and draw image on incoming samples (mostly used GDI or GDI+)
3. Implementing own filter and perform drawing in there. Can be used any mechanism here but mostly will be fine with GDI+.

Regards,
Maxim.
  Permalink  

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 365
1 Sergey Alexandrovich Kryukov 220
2 virusstorm 209
3 Kornfeld Eliyahu Peter 165
4 Andy Lanng 139
0 OriginalGriff 1,403
1 Sergey Alexandrovich Kryukov 970
2 Abhinav S 696
3 F-ES Sitecore 505
4 Suvendu Shekhar Giri 503


Advertise | Privacy | Mobile
Web03 | 2.8.150603.1 | Last Updated 19 Oct 2012
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100