Sygaldry
Loading...
Searching...
No Matches
sygbp-cstdio_reader.hpp
1#pragma once
2/*
3Copyright 2023 Travis J. West, https://traviswest.ca, Input Devices and Music
4Interaction Laboratory (IDMIL), Centre for Interdisciplinary Research in Music
5Media and Technology (CIRMMT), McGill University, Montréal, Canada, and Univ.
6Lille, Inria, CNRS, Centrale Lille, UMR 9189 CRIStAL, F-59000 Lille, France
7
8SPDX-License-Identifier: MIT
9*/
10
11
12#include <stdio.h>
13#include <stdlib.h>
14
15namespace sygaldry { namespace sygbp {
20
34{
35 int last_read;
36 bool ready()
37 {
38 last_read = getc(stdin);
39 return last_read != EOF;
40 }
41
42 char getchar()
43 {
44 return last_read;
45 }
46};
47
50} }
Command line input reader using standard IO calls.
Definition sygbp-cstdio_reader.hpp:34