Skip to content

Add query(Query q) to Element, mapping to gst_element_query. #94

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jan 17, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 18 additions & 1 deletion src/org/freedesktop/gstreamer/Element.java
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
/*
* Copyright (c) 2018 Neil C Smith
* Copyright (c) 2009 Levente Farkas
* Copyright (C) 2007 Wayne Meissner
* Copyright (C) 1999,2000 Erik Walthinsen <omega@cse.ogi.edu>
Expand Down Expand Up @@ -677,5 +678,21 @@ public ClockTime getStartTime() {
public void setStartTime(ClockTime time) {
GSTELEMENT_API.gst_element_set_start_time(this, time);
}

/**
* Performs a query on the element.
*
* For elements that don't implement a query handler, this function forwards
* the query to a random srcpad or to the peer of a random linked sinkpad of
* this element.
*
* Please note that some queries might need a running pipeline to work.
*
* @param query the Query to perform
* @return true if the query could be performed
*/
public boolean query(Query query) {
return GSTELEMENT_API.gst_element_query(this, query);
}

}