1 /*
2  * This file is part of gtkD.
3  *
4  * gtkD is free software; you can redistribute it and/or modify
5  * it under the terms of the GNU Lesser General Public License
6  * as published by the Free Software Foundation; either version 3
7  * of the License, or (at your option) any later version, with
8  * some exceptions, please read the COPYING file.
9  *
10  * gtkD is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13  * GNU Lesser General Public License for more details.
14  *
15  * You should have received a copy of the GNU Lesser General Public License
16  * along with gtkD; if not, write to the Free Software
17  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110, USA
18  */
19 
20 // generated automatically - do not change
21 // find conversion definition on APILookup.txt
22 // implement new conversion functionalities on the wrap.utils pakage
23 
24 
25 module gstreamer.ValueGst;
26 
27 private import glib.Str;
28 private import gobject.ObjectG;
29 private import gobject.Value;
30 private import gstreamer.Caps;
31 private import gstreamer.CapsFeatures;
32 private import gstreamer.Structure;
33 private import gstreamerc.gstreamer;
34 public  import gstreamerc.gstreamertypes;
35 
36 
37 public struct ValueGst
38 {
39 	/**
40 	 */
41 
42 	/**
43 	 * Determines if @value1 and @value2 can be compared.
44 	 *
45 	 * Params:
46 	 *     value1 = a value to compare
47 	 *     value2 = another value to compare
48 	 *
49 	 * Return: %TRUE if the values can be compared
50 	 */
51 	public static bool canCompare(Value value1, Value value2)
52 	{
53 		return gst_value_can_compare((value1 is null) ? null : value1.getValueStruct(), (value2 is null) ? null : value2.getValueStruct()) != 0;
54 	}
55 
56 	/**
57 	 * Determines if intersecting two values will produce a valid result.
58 	 * Two values will produce a valid intersection if they have the same
59 	 * type.
60 	 *
61 	 * Params:
62 	 *     value1 = a value to intersect
63 	 *     value2 = another value to intersect
64 	 *
65 	 * Return: %TRUE if the values can intersect
66 	 */
67 	public static bool canIntersect(Value value1, Value value2)
68 	{
69 		return gst_value_can_intersect((value1 is null) ? null : value1.getValueStruct(), (value2 is null) ? null : value2.getValueStruct()) != 0;
70 	}
71 
72 	/**
73 	 * Checks if it's possible to subtract @subtrahend from @minuend.
74 	 *
75 	 * Params:
76 	 *     minuend = the value to subtract from
77 	 *     subtrahend = the value to subtract
78 	 *
79 	 * Return: %TRUE if a subtraction is possible
80 	 */
81 	public static bool canSubtract(Value minuend, Value subtrahend)
82 	{
83 		return gst_value_can_subtract((minuend is null) ? null : minuend.getValueStruct(), (subtrahend is null) ? null : subtrahend.getValueStruct()) != 0;
84 	}
85 
86 	/**
87 	 * Determines if @value1 and @value2 can be non-trivially unioned.
88 	 * Any two values can be trivially unioned by adding both of them
89 	 * to a GstValueList.  However, certain types have the possibility
90 	 * to be unioned in a simpler way.  For example, an integer range
91 	 * and an integer can be unioned if the integer is a subset of the
92 	 * integer range.  If there is the possibility that two values can
93 	 * be unioned, this function returns %TRUE.
94 	 *
95 	 * Params:
96 	 *     value1 = a value to union
97 	 *     value2 = another value to union
98 	 *
99 	 * Return: %TRUE if there is a function allowing the two values to
100 	 *     be unioned.
101 	 */
102 	public static bool canUnion(Value value1, Value value2)
103 	{
104 		return gst_value_can_union((value1 is null) ? null : value1.getValueStruct(), (value2 is null) ? null : value2.getValueStruct()) != 0;
105 	}
106 
107 	/**
108 	 * Compares @value1 and @value2.  If @value1 and @value2 cannot be
109 	 * compared, the function returns GST_VALUE_UNORDERED.  Otherwise,
110 	 * if @value1 is greater than @value2, GST_VALUE_GREATER_THAN is returned.
111 	 * If @value1 is less than @value2, GST_VALUE_LESS_THAN is returned.
112 	 * If the values are equal, GST_VALUE_EQUAL is returned.
113 	 *
114 	 * Params:
115 	 *     value1 = a value to compare
116 	 *     value2 = another value to compare
117 	 *
118 	 * Return: comparison result
119 	 */
120 	public static int compare(Value value1, Value value2)
121 	{
122 		return gst_value_compare((value1 is null) ? null : value1.getValueStruct(), (value2 is null) ? null : value2.getValueStruct());
123 	}
124 
125 	/**
126 	 * Tries to deserialize a string into the type specified by the given GValue.
127 	 * If the operation succeeds, %TRUE is returned, %FALSE otherwise.
128 	 *
129 	 * Params:
130 	 *     dest = #GValue to fill with contents of
131 	 *         deserialization
132 	 *     src = string to deserialize
133 	 *
134 	 * Return: %TRUE on success
135 	 */
136 	public static bool deserialize(out Value dest, string src)
137 	{
138 		GValue* outdest = new GValue;
139 		
140 		auto p = gst_value_deserialize(outdest, Str.toStringz(src)) != 0;
141 		
142 		dest = ObjectG.getDObject!(Value)(outdest);
143 		
144 		return p;
145 	}
146 
147 	/**
148 	 * Fixate @src into a new value @dest.
149 	 * For ranges, the first element is taken. For lists and arrays, the
150 	 * first item is fixated and returned.
151 	 * If @src is already fixed, this function returns %FALSE.
152 	 *
153 	 * Params:
154 	 *     dest = the #GValue destination
155 	 *     src = the #GValue to fixate
156 	 *
157 	 * Return: %TRUE if @dest contains a fixated version of @src.
158 	 */
159 	public static bool fixate(Value dest, Value src)
160 	{
161 		return gst_value_fixate((dest is null) ? null : dest.getValueStruct(), (src is null) ? null : src.getValueStruct()) != 0;
162 	}
163 
164 	/**
165 	 * Multiplies the two #GValue items containing a #GST_TYPE_FRACTION and sets
166 	 * @product to the product of the two fractions.
167 	 *
168 	 * Params:
169 	 *     product = a GValue initialized to #GST_TYPE_FRACTION
170 	 *     factor1 = a GValue initialized to #GST_TYPE_FRACTION
171 	 *     factor2 = a GValue initialized to #GST_TYPE_FRACTION
172 	 *
173 	 * Return: %FALSE in case of an error (like integer overflow), %TRUE otherwise.
174 	 */
175 	public static bool fractionMultiply(Value product, Value factor1, Value factor2)
176 	{
177 		return gst_value_fraction_multiply((product is null) ? null : product.getValueStruct(), (factor1 is null) ? null : factor1.getValueStruct(), (factor2 is null) ? null : factor2.getValueStruct()) != 0;
178 	}
179 
180 	/**
181 	 * Subtracts the @subtrahend from the @minuend and sets @dest to the result.
182 	 *
183 	 * Params:
184 	 *     dest = a GValue initialized to #GST_TYPE_FRACTION
185 	 *     minuend = a GValue initialized to #GST_TYPE_FRACTION
186 	 *     subtrahend = a GValue initialized to #GST_TYPE_FRACTION
187 	 *
188 	 * Return: %FALSE in case of an error (like integer overflow), %TRUE otherwise.
189 	 */
190 	public static bool fractionSubtract(Value dest, Value minuend, Value subtrahend)
191 	{
192 		return gst_value_fraction_subtract((dest is null) ? null : dest.getValueStruct(), (minuend is null) ? null : minuend.getValueStruct(), (subtrahend is null) ? null : subtrahend.getValueStruct()) != 0;
193 	}
194 
195 	/**
196 	 * Gets the bitmask specified by @value.
197 	 *
198 	 * Params:
199 	 *     value = a GValue initialized to #GST_TYPE_BITMASK
200 	 *
201 	 * Return: the bitmask.
202 	 */
203 	public static ulong getBitmask(Value value)
204 	{
205 		return gst_value_get_bitmask((value is null) ? null : value.getValueStruct());
206 	}
207 
208 	/**
209 	 * Gets the contents of @value. The reference count of the returned
210 	 * #GstCaps will not be modified, therefore the caller must take one
211 	 * before getting rid of the @value.
212 	 *
213 	 * Params:
214 	 *     value = a GValue initialized to GST_TYPE_CAPS
215 	 *
216 	 * Return: the contents of @value
217 	 */
218 	public static Caps getCaps(Value value)
219 	{
220 		auto p = gst_value_get_caps((value is null) ? null : value.getValueStruct());
221 		
222 		if(p is null)
223 		{
224 			return null;
225 		}
226 		
227 		return ObjectG.getDObject!(Caps)(cast(GstCaps*) p);
228 	}
229 
230 	/**
231 	 * Gets the contents of @value.
232 	 *
233 	 * Params:
234 	 *     value = a GValue initialized to GST_TYPE_CAPS_FEATURES
235 	 *
236 	 * Return: the contents of @value
237 	 */
238 	public static CapsFeatures getCapsFeatures(Value value)
239 	{
240 		auto p = gst_value_get_caps_features((value is null) ? null : value.getValueStruct());
241 		
242 		if(p is null)
243 		{
244 			return null;
245 		}
246 		
247 		return ObjectG.getDObject!(CapsFeatures)(cast(GstCapsFeatures*) p);
248 	}
249 
250 	/**
251 	 * Gets the maximum of the range specified by @value.
252 	 *
253 	 * Params:
254 	 *     value = a GValue initialized to GST_TYPE_DOUBLE_RANGE
255 	 *
256 	 * Return: the maximum of the range
257 	 */
258 	public static double getDoubleRangeMax(Value value)
259 	{
260 		return gst_value_get_double_range_max((value is null) ? null : value.getValueStruct());
261 	}
262 
263 	/**
264 	 * Gets the minimum of the range specified by @value.
265 	 *
266 	 * Params:
267 	 *     value = a GValue initialized to GST_TYPE_DOUBLE_RANGE
268 	 *
269 	 * Return: the minimum of the range
270 	 */
271 	public static double getDoubleRangeMin(Value value)
272 	{
273 		return gst_value_get_double_range_min((value is null) ? null : value.getValueStruct());
274 	}
275 
276 	/**
277 	 * Retrieve the flags field of a GstFlagSet @value.
278 	 *
279 	 * Params:
280 	 *     value = a GValue initialized to #GST_TYPE_FLAG_SET
281 	 *
282 	 * Return: the flags field of the flagset instance.
283 	 *
284 	 * Since: 1.6
285 	 */
286 	public static uint getFlagsetFlags(Value value)
287 	{
288 		return gst_value_get_flagset_flags((value is null) ? null : value.getValueStruct());
289 	}
290 
291 	/**
292 	 * Retrieve the mask field of a GstFlagSet @value.
293 	 *
294 	 * Params:
295 	 *     value = a GValue initialized to #GST_TYPE_FLAG_SET
296 	 *
297 	 * Return: the mask field of the flagset instance.
298 	 *
299 	 * Since: 1.6
300 	 */
301 	public static uint getFlagsetMask(Value value)
302 	{
303 		return gst_value_get_flagset_mask((value is null) ? null : value.getValueStruct());
304 	}
305 
306 	/**
307 	 * Sets @value to the flags and mask values provided in @flags and @mask.
308 	 * The @flags value indicates the values of flags, the @mask represents
309 	 * which bits in the flag value have been set, and which are "don't care"
310 	 *
311 	 * Params:
312 	 *     value = a GValue initialized to %GST_TYPE_FLAG_SET
313 	 *     flags = The value of the flags set or unset
314 	 *     mask = The mask indicate which flags bits must match for comparisons
315 	 *
316 	 * Since: 1.6
317 	 */
318 	public static void setFlagset(Value value, uint flags, uint mask)
319 	{
320 		gst_value_set_flagset((value is null) ? null : value.getValueStruct(), flags, mask);
321 	}
322 
323 	/**
324 	 * Gets the denominator of the fraction specified by @value.
325 	 *
326 	 * Params:
327 	 *     value = a GValue initialized to #GST_TYPE_FRACTION
328 	 *
329 	 * Return: the denominator of the fraction.
330 	 */
331 	public static int getFractionDenominator(Value value)
332 	{
333 		return gst_value_get_fraction_denominator((value is null) ? null : value.getValueStruct());
334 	}
335 
336 	/**
337 	 * Gets the numerator of the fraction specified by @value.
338 	 *
339 	 * Params:
340 	 *     value = a GValue initialized to #GST_TYPE_FRACTION
341 	 *
342 	 * Return: the numerator of the fraction.
343 	 */
344 	public static int getFractionNumerator(Value value)
345 	{
346 		return gst_value_get_fraction_numerator((value is null) ? null : value.getValueStruct());
347 	}
348 
349 	/**
350 	 * Gets the maximum of the range specified by @value.
351 	 *
352 	 * Params:
353 	 *     value = a GValue initialized to GST_TYPE_FRACTION_RANGE
354 	 *
355 	 * Return: the maximum of the range
356 	 */
357 	public static Value getFractionRangeMax(Value value)
358 	{
359 		auto p = gst_value_get_fraction_range_max((value is null) ? null : value.getValueStruct());
360 		
361 		if(p is null)
362 		{
363 			return null;
364 		}
365 		
366 		return ObjectG.getDObject!(Value)(cast(GValue*) p);
367 	}
368 
369 	/**
370 	 * Gets the minimum of the range specified by @value.
371 	 *
372 	 * Params:
373 	 *     value = a GValue initialized to GST_TYPE_FRACTION_RANGE
374 	 *
375 	 * Return: the minimum of the range
376 	 */
377 	public static Value getFractionRangeMin(Value value)
378 	{
379 		auto p = gst_value_get_fraction_range_min((value is null) ? null : value.getValueStruct());
380 		
381 		if(p is null)
382 		{
383 			return null;
384 		}
385 		
386 		return ObjectG.getDObject!(Value)(cast(GValue*) p);
387 	}
388 
389 	/**
390 	 * Gets the maximum of the range specified by @value.
391 	 *
392 	 * Params:
393 	 *     value = a GValue initialized to GST_TYPE_INT64_RANGE
394 	 *
395 	 * Return: the maximum of the range
396 	 */
397 	public static long getInt64RangeMax(Value value)
398 	{
399 		return gst_value_get_int64_range_max((value is null) ? null : value.getValueStruct());
400 	}
401 
402 	/**
403 	 * Gets the minimum of the range specified by @value.
404 	 *
405 	 * Params:
406 	 *     value = a GValue initialized to GST_TYPE_INT64_RANGE
407 	 *
408 	 * Return: the minimum of the range
409 	 */
410 	public static long getInt64RangeMin(Value value)
411 	{
412 		return gst_value_get_int64_range_min((value is null) ? null : value.getValueStruct());
413 	}
414 
415 	/**
416 	 * Gets the step of the range specified by @value.
417 	 *
418 	 * Params:
419 	 *     value = a GValue initialized to GST_TYPE_INT64_RANGE
420 	 *
421 	 * Return: the step of the range
422 	 */
423 	public static long getInt64RangeStep(Value value)
424 	{
425 		return gst_value_get_int64_range_step((value is null) ? null : value.getValueStruct());
426 	}
427 
428 	/**
429 	 * Gets the maximum of the range specified by @value.
430 	 *
431 	 * Params:
432 	 *     value = a GValue initialized to GST_TYPE_INT_RANGE
433 	 *
434 	 * Return: the maximum of the range
435 	 */
436 	public static int getIntRangeMax(Value value)
437 	{
438 		return gst_value_get_int_range_max((value is null) ? null : value.getValueStruct());
439 	}
440 
441 	/**
442 	 * Gets the minimum of the range specified by @value.
443 	 *
444 	 * Params:
445 	 *     value = a GValue initialized to GST_TYPE_INT_RANGE
446 	 *
447 	 * Return: the minimum of the range
448 	 */
449 	public static int getIntRangeMin(Value value)
450 	{
451 		return gst_value_get_int_range_min((value is null) ? null : value.getValueStruct());
452 	}
453 
454 	/**
455 	 * Gets the step of the range specified by @value.
456 	 *
457 	 * Params:
458 	 *     value = a GValue initialized to GST_TYPE_INT_RANGE
459 	 *
460 	 * Return: the step of the range
461 	 */
462 	public static int getIntRangeStep(Value value)
463 	{
464 		return gst_value_get_int_range_step((value is null) ? null : value.getValueStruct());
465 	}
466 
467 	/**
468 	 * Gets the contents of @value.
469 	 *
470 	 * Params:
471 	 *     value = a GValue initialized to GST_TYPE_STRUCTURE
472 	 *
473 	 * Return: the contents of @value
474 	 */
475 	public static Structure getStructure(Value value)
476 	{
477 		auto p = gst_value_get_structure((value is null) ? null : value.getValueStruct());
478 		
479 		if(p is null)
480 		{
481 			return null;
482 		}
483 		
484 		return ObjectG.getDObject!(Structure)(cast(GstStructure*) p);
485 	}
486 
487 	/**
488 	 * Initialises the target value to be of the same type as source and then copies
489 	 * the contents from source to target.
490 	 *
491 	 * Params:
492 	 *     dest = the target value
493 	 *     src = the source value
494 	 */
495 	public static void initAndCopy(out Value dest, Value src)
496 	{
497 		GValue* outdest = new GValue;
498 		
499 		gst_value_init_and_copy(outdest, (src is null) ? null : src.getValueStruct());
500 		
501 		dest = ObjectG.getDObject!(Value)(outdest);
502 	}
503 
504 	/**
505 	 * Calculates the intersection of two values.  If the values have
506 	 * a non-empty intersection, the value representing the intersection
507 	 * is placed in @dest, unless %NULL.  If the intersection is non-empty,
508 	 * @dest is not modified.
509 	 *
510 	 * Params:
511 	 *     dest = a uninitialized #GValue that will hold the calculated
512 	 *         intersection value. May be %NULL if the resulting set if not
513 	 *         needed.
514 	 *     value1 = a value to intersect
515 	 *     value2 = another value to intersect
516 	 *
517 	 * Return: %TRUE if the intersection is non-empty
518 	 */
519 	public static bool intersect(out Value dest, Value value1, Value value2)
520 	{
521 		GValue* outdest = new GValue;
522 		
523 		auto p = gst_value_intersect(outdest, (value1 is null) ? null : value1.getValueStruct(), (value2 is null) ? null : value2.getValueStruct()) != 0;
524 		
525 		dest = ObjectG.getDObject!(Value)(outdest);
526 		
527 		return p;
528 	}
529 
530 	/**
531 	 * Tests if the given GValue, if available in a GstStructure (or any other
532 	 * container) contains a "fixed" (which means: one value) or an "unfixed"
533 	 * (which means: multiple possible values, such as data lists or data
534 	 * ranges) value.
535 	 *
536 	 * Params:
537 	 *     value = the #GValue to check
538 	 *
539 	 * Return: true if the value is "fixed".
540 	 */
541 	public static bool isFixed(Value value)
542 	{
543 		return gst_value_is_fixed((value is null) ? null : value.getValueStruct()) != 0;
544 	}
545 
546 	/**
547 	 * Check that @value1 is a subset of @value2.
548 	 *
549 	 * Params:
550 	 *     value1 = a #GValue
551 	 *     value2 = a #GValue
552 	 *
553 	 * Return: %TRUE is @value1 is a subset of @value2
554 	 */
555 	public static bool isSubset(Value value1, Value value2)
556 	{
557 		return gst_value_is_subset((value1 is null) ? null : value1.getValueStruct(), (value2 is null) ? null : value2.getValueStruct()) != 0;
558 	}
559 
560 	/**
561 	 * Registers functions to perform calculations on #GValue items of a given
562 	 * type. Each type can only be added once.
563 	 *
564 	 * Params:
565 	 *     table = structure containing functions to register
566 	 */
567 	public static void register(GstValueTable* table)
568 	{
569 		gst_value_register(table);
570 	}
571 
572 	/**
573 	 * tries to transform the given @value into a string representation that allows
574 	 * getting back this string later on using gst_value_deserialize().
575 	 *
576 	 * Free-function: g_free
577 	 *
578 	 * Params:
579 	 *     value = a #GValue to serialize
580 	 *
581 	 * Return: the serialization for @value
582 	 *     or %NULL if none exists
583 	 */
584 	public static string serialize(Value value)
585 	{
586 		return Str.toString(gst_value_serialize((value is null) ? null : value.getValueStruct()));
587 	}
588 
589 	/**
590 	 * Sets @value to the bitmask specified by @bitmask.
591 	 *
592 	 * Params:
593 	 *     value = a GValue initialized to #GST_TYPE_BITMASK
594 	 *     bitmask = the bitmask
595 	 */
596 	public static void setBitmask(Value value, ulong bitmask)
597 	{
598 		gst_value_set_bitmask((value is null) ? null : value.getValueStruct(), bitmask);
599 	}
600 
601 	/**
602 	 * Sets the contents of @value to @caps. A reference to the
603 	 * provided @caps will be taken by the @value.
604 	 *
605 	 * Params:
606 	 *     value = a GValue initialized to GST_TYPE_CAPS
607 	 *     caps = the caps to set the value to
608 	 */
609 	public static void setCaps(Value value, Caps caps)
610 	{
611 		gst_value_set_caps((value is null) ? null : value.getValueStruct(), (caps is null) ? null : caps.getCapsStruct());
612 	}
613 
614 	/**
615 	 * Sets the contents of @value to @features.
616 	 *
617 	 * Params:
618 	 *     value = a GValue initialized to GST_TYPE_CAPS_FEATURES
619 	 *     features = the features to set the value to
620 	 */
621 	public static void setCapsFeatures(Value value, CapsFeatures features)
622 	{
623 		gst_value_set_caps_features((value is null) ? null : value.getValueStruct(), (features is null) ? null : features.getCapsFeaturesStruct());
624 	}
625 
626 	/**
627 	 * Sets @value to the range specified by @start and @end.
628 	 *
629 	 * Params:
630 	 *     value = a GValue initialized to GST_TYPE_DOUBLE_RANGE
631 	 *     start = the start of the range
632 	 *     end = the end of the range
633 	 */
634 	public static void setDoubleRange(Value value, double start, double end)
635 	{
636 		gst_value_set_double_range((value is null) ? null : value.getValueStruct(), start, end);
637 	}
638 
639 	/**
640 	 * Sets @value to the fraction specified by @numerator over @denominator.
641 	 * The fraction gets reduced to the smallest numerator and denominator,
642 	 * and if necessary the sign is moved to the numerator.
643 	 *
644 	 * Params:
645 	 *     value = a GValue initialized to #GST_TYPE_FRACTION
646 	 *     numerator = the numerator of the fraction
647 	 *     denominator = the denominator of the fraction
648 	 */
649 	public static void setFraction(Value value, int numerator, int denominator)
650 	{
651 		gst_value_set_fraction((value is null) ? null : value.getValueStruct(), numerator, denominator);
652 	}
653 
654 	/**
655 	 * Sets @value to the range specified by @start and @end.
656 	 *
657 	 * Params:
658 	 *     value = a GValue initialized to GST_TYPE_FRACTION_RANGE
659 	 *     start = the start of the range (a GST_TYPE_FRACTION GValue)
660 	 *     end = the end of the range (a GST_TYPE_FRACTION GValue)
661 	 */
662 	public static void setFractionRange(Value value, Value start, Value end)
663 	{
664 		gst_value_set_fraction_range((value is null) ? null : value.getValueStruct(), (start is null) ? null : start.getValueStruct(), (end is null) ? null : end.getValueStruct());
665 	}
666 
667 	/**
668 	 * Sets @value to the range specified by @numerator_start/@denominator_start
669 	 * and @numerator_end/@denominator_end.
670 	 *
671 	 * Params:
672 	 *     value = a GValue initialized to GST_TYPE_FRACTION_RANGE
673 	 *     numeratorStart = the numerator start of the range
674 	 *     denominatorStart = the denominator start of the range
675 	 *     numeratorEnd = the numerator end of the range
676 	 *     denominatorEnd = the denominator end of the range
677 	 */
678 	public static void setFractionRangeFull(Value value, int numeratorStart, int denominatorStart, int numeratorEnd, int denominatorEnd)
679 	{
680 		gst_value_set_fraction_range_full((value is null) ? null : value.getValueStruct(), numeratorStart, denominatorStart, numeratorEnd, denominatorEnd);
681 	}
682 
683 	/**
684 	 * Sets @value to the range specified by @start and @end.
685 	 *
686 	 * Params:
687 	 *     value = a GValue initialized to GST_TYPE_INT64_RANGE
688 	 *     start = the start of the range
689 	 *     end = the end of the range
690 	 */
691 	public static void setInt64Range(Value value, long start, long end)
692 	{
693 		gst_value_set_int64_range((value is null) ? null : value.getValueStruct(), start, end);
694 	}
695 
696 	/**
697 	 * Sets @value to the range specified by @start, @end and @step.
698 	 *
699 	 * Params:
700 	 *     value = a GValue initialized to GST_TYPE_INT64_RANGE
701 	 *     start = the start of the range
702 	 *     end = the end of the range
703 	 *     step = the step of the range
704 	 */
705 	public static void setInt64RangeStep(Value value, long start, long end, long step)
706 	{
707 		gst_value_set_int64_range_step((value is null) ? null : value.getValueStruct(), start, end, step);
708 	}
709 
710 	/**
711 	 * Sets @value to the range specified by @start and @end.
712 	 *
713 	 * Params:
714 	 *     value = a GValue initialized to GST_TYPE_INT_RANGE
715 	 *     start = the start of the range
716 	 *     end = the end of the range
717 	 */
718 	public static void setIntRange(Value value, int start, int end)
719 	{
720 		gst_value_set_int_range((value is null) ? null : value.getValueStruct(), start, end);
721 	}
722 
723 	/**
724 	 * Sets @value to the range specified by @start, @end and @step.
725 	 *
726 	 * Params:
727 	 *     value = a GValue initialized to GST_TYPE_INT_RANGE
728 	 *     start = the start of the range
729 	 *     end = the end of the range
730 	 *     step = the step of the range
731 	 */
732 	public static void setIntRangeStep(Value value, int start, int end, int step)
733 	{
734 		gst_value_set_int_range_step((value is null) ? null : value.getValueStruct(), start, end, step);
735 	}
736 
737 	/**
738 	 * Sets the contents of @value to @structure.  The actual
739 	 *
740 	 * Params:
741 	 *     value = a GValue initialized to GST_TYPE_STRUCTURE
742 	 *     structure = the structure to set the value to
743 	 */
744 	public static void setStructure(Value value, Structure structure)
745 	{
746 		gst_value_set_structure((value is null) ? null : value.getValueStruct(), (structure is null) ? null : structure.getStructureStruct());
747 	}
748 
749 	/**
750 	 * Subtracts @subtrahend from @minuend and stores the result in @dest.
751 	 * Note that this means subtraction as in sets, not as in mathematics.
752 	 *
753 	 * Params:
754 	 *     dest = the destination value
755 	 *         for the result if the subtraction is not empty. May be %NULL,
756 	 *         in which case the resulting set will not be computed, which can
757 	 *         give a fair speedup.
758 	 *     minuend = the value to subtract from
759 	 *     subtrahend = the value to subtract
760 	 *
761 	 * Return: %TRUE if the subtraction is not empty
762 	 */
763 	public static bool subtract(out Value dest, Value minuend, Value subtrahend)
764 	{
765 		GValue* outdest = new GValue;
766 		
767 		auto p = gst_value_subtract(outdest, (minuend is null) ? null : minuend.getValueStruct(), (subtrahend is null) ? null : subtrahend.getValueStruct()) != 0;
768 		
769 		dest = ObjectG.getDObject!(Value)(outdest);
770 		
771 		return p;
772 	}
773 
774 	/**
775 	 * Creates a GValue corresponding to the union of @value1 and @value2.
776 	 *
777 	 * Params:
778 	 *     dest = the destination value
779 	 *     value1 = a value to union
780 	 *     value2 = another value to union
781 	 *
782 	 * Return: %TRUE if the union succeeded.
783 	 */
784 	public static bool unio(out Value dest, Value value1, Value value2)
785 	{
786 		GValue* outdest = new GValue;
787 		
788 		auto p = gst_value_union(outdest, (value1 is null) ? null : value1.getValueStruct(), (value2 is null) ? null : value2.getValueStruct()) != 0;
789 		
790 		dest = ObjectG.getDObject!(Value)(outdest);
791 		
792 		return p;
793 	}
794 }