Created
November 24, 2014 08:33
-
-
Save TIS-Edgar/6342b740dc4fa84bbfa1 to your computer and use it in GitHub Desktop.
aravis_gst_exampple_mono.patch
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/examples/aravis/c/gstexample.c b/examples/aravis/c/gstexample.c | |
index 0c10eba..499fc7e 100644 | |
--- a/examples/aravis/c/gstexample.c | |
+++ b/examples/aravis/c/gstexample.c | |
@@ -39,10 +39,10 @@ | |
#include <arv.h> | |
/* our camera variables */ | |
-#define CAMERA "The Imaging Source Europe GmbH-46210199" | |
-#define WIDTH 2592 | |
-#define HEIGHT 1944 | |
+#define CAMERA "The Imaging Source Europe GmbH-46310421" | |
+#define WIDTH 1600 | |
+#define HEIGHT 1200 | |
#define INIT_FPS 15 | |
/* the format description gbrg may vary between camera types. | |
@@ -126,8 +126,8 @@ void framerate_value_changed (Win* we) | |
there will be an undefined behaviour that can crash your application | |
Currently width and height have to be mentioned, else undefined behaviour will be experienced. | |
*/ | |
- caps = gst_caps_new_simple (FORMAT_COLOR, | |
- "format", G_TYPE_STRING, PATTERN, | |
+ caps = gst_caps_new_simple (FORMAT_MONO, | |
+ //"format", G_TYPE_STRING, PATTERN, | |
"framerate", GST_TYPE_FRACTION, num, denom, | |
"width", G_TYPE_INT, WIDTH, | |
"height",G_TYPE_INT, HEIGHT, | |
@@ -260,8 +260,8 @@ void create_pipeline() | |
p.sink = gst_element_factory_make ("ximagesink", "output"); | |
/* define our conditions and set them for the capsfilter */ | |
- caps = gst_caps_new_simple (FORMAT_COLOR, | |
- "format", G_TYPE_STRING, PATTERN, | |
+ caps = gst_caps_new_simple (FORMAT_MONO, | |
+ //"format", G_TYPE_STRING, PATTERN, | |
"bpp", G_TYPE_INT, 8, | |
"depth", G_TYPE_INT, 8, | |
"width", G_TYPE_INT, WIDTH, | |
@@ -330,7 +330,7 @@ void create_pipeline() | |
gst_bin_add_many (GST_BIN (p.pipeline), | |
p.source, | |
p.capsfilter, | |
- p.bayer, | |
+ //p.bayer, | |
p.queue, | |
p.colorspace, | |
p.sink, | |
@@ -339,7 +339,7 @@ void create_pipeline() | |
/* link the elements together */ | |
gst_element_link_many (p.source, | |
p.capsfilter, | |
- p.bayer, | |
+ // p.bayer, | |
p.queue, | |
p.colorspace, | |
p.sink, |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Apply with:
cd examples/aravis/c
patch -p1 < aravis_gst_exampple_mono.patch