Grab a buffer to an unsigned char*

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Grab a buffer to an unsigned char*

Gabriel Duarte
Hello all!I'm building an application to capture data from V4L2 cameras. It  is working well, I can access my camera and see the images, etc..I'd like get the buffer that gstreamer gives me from my camera and put into an unsigner char*, RAW data,  to make possible process them, apply filters, etc.
Thanks in advance!

--
"I hear that if you play the NT 4.0 CD backwards, you get a satanic
message"

"...That's nothing. If you play it forward, it installs NT 4.0!"

Gabriel Duarte
Linux User #471185
Rio de Janeiro - RJ
http://kinuxlinux.org/gabriel_duarte

Phones:
(55) (21) 9463-7760
(55) (21) 2464-9302
(55) (21) 2529-5080

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Grab a buffer to an unsigned char*

Thiago Sousa Santos-2


On Wed, Aug 12, 2009 at 3:54 PM, Gabriel Duarte <[hidden email]> wrote:
Hello all!I'm building an application to capture data from V4L2 cameras. It  is working well, I can access my camera and see the images, etc..I'd like get the buffer that gstreamer gives me from my camera and put into an unsigner char*, RAW data,  to make possible process them, apply filters, etc.
Thanks in advance!

You can use appsink as a sink to get the contents of the buffers, or if you'd like to write filters and pass the data onwards you might also write a new plugin/element that does your magic and pushes the buffer downstream to the next element. But that depends on what you're trying to achieve.
 


--
"I hear that if you play the NT 4.0 CD backwards, you get a satanic
message"

"...That's nothing. If you play it forward, it installs NT 4.0!"

Gabriel Duarte
Linux User #471185
Rio de Janeiro - RJ
http://kinuxlinux.org/gabriel_duarte

Phones:
(55) (21) 9463-7760
(55) (21) 2464-9302
(55) (21) 2529-5080

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel




--
Thiago Sousa Santos

Embedded Systems and Pervasive Computing Lab (Embedded)
Center of Electrical Engineering and Informatics (CEEI)
Federal University of Campina Grande (UFCG)

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Grab a buffer to an unsigned char*

Gabriel Duarte
Thanks!I solved using GST_BUFFER_DATA(), signal-handoffs and fakesink on my pipeline! Best regards!

On Wed, Aug 12, 2009 at 7:27 PM, thiagoss <[hidden email]> wrote:


On Wed, Aug 12, 2009 at 3:54 PM, Gabriel Duarte <[hidden email]> wrote:
Hello all!I'm building an application to capture data from V4L2 cameras. It  is working well, I can access my camera and see the images, etc..I'd like get the buffer that gstreamer gives me from my camera and put into an unsigner char*, RAW data,  to make possible process them, apply filters, etc.
Thanks in advance!

You can use appsink as a sink to get the contents of the buffers, or if you'd like to write filters and pass the data onwards you might also write a new plugin/element that does your magic and pushes the buffer downstream to the next element. But that depends on what you're trying to achieve.
 


--
"I hear that if you play the NT 4.0 CD backwards, you get a satanic
message"

"...That's nothing. If you play it forward, it installs NT 4.0!"

Gabriel Duarte
Linux User #471185
Rio de Janeiro - RJ
http://kinuxlinux.org/gabriel_duarte

Phones:
(55) (21) 9463-7760
(55) (21) 2464-9302
(55) (21) 2529-5080

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel




--
Thiago Sousa Santos

Embedded Systems and Pervasive Computing Lab (Embedded)
Center of Electrical Engineering and Informatics (CEEI)
Federal University of Campina Grande (UFCG)

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel




--
"I hear that if you play the NT 4.0 CD backwards, you get a satanic
message"

"...That's nothing. If you play it forward, it installs NT 4.0!"

Gabriel Duarte
Linux User #471185
Rio de Janeiro - RJ
http://kinuxlinux.org/gabriel_duarte

Phones:
(55) (21) 9463-7760
(55) (21) 2464-9302
(55) (21) 2529-5080

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel