R/ProTrackR2-package.R

Defines functions .onLoad .onUnload

#' @keywords internal
"_PACKAGE"
NULL

.onUnload <- function(libpath) {
  ## Cleans up memory allocated by pt_init_()
  pt_cleanup_()
  ## Unload the dynamic binding (particularly useful on Windows)
  library.dynam.unload("ProTrackR2", libpath)
}

.onLoad <- function(libname, pkgname) {
  ## Initializes ProTracker configuration and audio buffer
  pt_init_()
}

#' @useDynLib ProTrackR2, .registration = TRUE
NULL

Try the ProTrackR2 package in your browser

Any scripts or data that you put into this service are public.

ProTrackR2 documentation built on April 3, 2025, 9:21 p.m.