R/RcppExports.R

Defines functions .cppCountForward .cppBroadcast .cppModelDensity .cppModelLongNote .cppModelManipulation .cppSimulateKey

Documented in .cppModelLongNote .cppModelManipulation .cppSimulateKey

# Generated by using Rcpp::compileAttributes() -> do not edit by hand
# Generator token: 10BE3573-1514-4C36-9D1C-5A225CD40393

.cppCountForward <- function(unq_offsets, obj_offsets, window, is_sorted, obj_weights) {
    .Call(`_osutools_cppCountForward`, unq_offsets, obj_offsets, window, is_sorted, obj_weights)
}

.cppBroadcast <- function(offsets, resets) {
    .Call(`_osutools_cppBroadcast`, offsets, resets)
}

.cppModelDensity <- function(unq_offsets, obj_offsets, window, is_sorted = FALSE) {
    .Call(`_osutools_cppModelDensity`, unq_offsets, obj_offsets, window, is_sorted)
}

#' Helps model.longNote in speeding up operations
#'
#' @param chart A casted chart provided via model.longNote
#' @param longNoteStartName The string indicating the start of a long note
#' @param longNoteEndName The string indicating the start of a long note
#' @param newName The string indicating the replaced name of long note bodies
#' @param labelStart A boolean indicating if the start of the long notes must
#' be labelled
#' @param labelEnd A boolean indicating if the end of the long notes must be
#' labelled
#'
#' @export
#'
.cppModelLongNote <- function(chart, longNoteStartName, longNoteEndName, newName, labelStart, labelEnd) {
    .Call(`_osutools_cppModelLongNote`, chart, longNoteStartName, longNoteEndName, newName, labelStart, labelEnd)
}

#' Helps model.manipulation in speeding up operations
#'
#' @description Calculates how many notes in front of window.
#'
#' This depends heavily on cppCountForward, refer to modelManipulation.R for
#' correct usage.
#'
#' @param unq_offsets a Numeric Vector of the offsets to check on
#' @param obj_offsets a List of the objects offsets
#' @param window a double indicating the window of the check
#' @param is_sorted a boolean indicating if the vectors are sorted, if they
#' aren't, they will be sorted.
#'
#' @export
#'
.cppModelManipulation <- function(unq_offsets, obj_offsets, window = 200, is_sorted = FALSE) {
    .Call(`_osutools_cppModelManipulation`, unq_offsets, obj_offsets, window, is_sorted)
}

#' Simulates stress using a offset and value vector
#'
#' @param offsets Offsets of the values used to indicate spikes
#' @param values Spike values used to increase stress
#' @param decay_ms Stress decay per ms
#' @param decay_perc_s Stress decay per second
#' @param stress_init Initial Stress
#'
#' @export
.cppSimulateKey <- function(offsets, values, decay_ms = 0.0, decay_perc_s = 0.1, stress_init = 0.0) {
    .Call(`_osutools_cppSimulateKey`, offsets, values, decay_ms, decay_perc_s, stress_init)
}
Eve-ning/osutools documentation built on Aug. 5, 2019, 4:56 a.m.