Skip to content

Commit

Permalink
Prepare release.
Browse files Browse the repository at this point in the history
  • Loading branch information
sjmgarnier committed Jan 30, 2024
1 parent 24fb275 commit 6e77dbe
Show file tree
Hide file tree
Showing 183 changed files with 1,283 additions and 68,750 deletions.
10 changes: 5 additions & 5 deletions NAMESPACE
Original file line number Diff line number Diff line change
Expand Up @@ -67,13 +67,8 @@ export("%i^%")
export("%i|%")
export("frame<-")
export(CLAHE)
export(Image)
export(LUT)
export(ORBkeypoints)
export(Queue)
export(Stream)
export(Video)
export(VideoWriter)
export(absdiff)
export(adaptiveThreshold)
export(add)
Expand Down Expand Up @@ -260,7 +255,12 @@ export(writeFrame)
export(writeMulti)
export(writerOuput)
export(zeros)
exportClasses(Image)
exportClasses(Queue)
exportClasses(Stream)
exportClasses(Video)
exportClasses(VideoStack)
exportClasses(VideoWriter)
import(ROpenCVLite)
import(Rcpp)
import(methods)
Expand Down
25 changes: 20 additions & 5 deletions R/ImageClass.R
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,11 @@
#'
#' @docType class
#'
#' @description \code{Image} objects are the base objects of the \pkg{\link{Rvision}}
#' package. They contain an \href{http://opencv.org/}{OpenCV} image that can
#' originate from an image file, an array, a video file or a video stream.
#' This image can be manipulated using the functions of \pkg{\link{Rvision}}.
#' @description \code{Image} objects are the base objects of the
#' \pkg{\link{Rvision}} package. They contain an
#' \href{http://opencv.org/}{OpenCV} image that can originate from an image
#' file, an array, a video file or a video stream. This image can be
#' manipulated using the functions of \pkg{\link{Rvision}}.
#'
#' @slot depth A function returning the bit depth of the object.
#'
Expand All @@ -34,7 +35,21 @@
#' @seealso \code{\link{image}}, \code{\link{Video}}, \code{\link{Stream}}
#'
#' @export
"Image"
setClass("Image",
representation(
cpp = "C++Object"
),
prototype(
cpp = NULL
),
validity = function(object) {
if (is.null(object@cpp) || is(object@cpp, "Rcpp_Image")) {
return(TRUE)
} else {
return(FALSE)
}
}
)


#' @title Create an Object of Class \code{Image}
Expand Down
18 changes: 16 additions & 2 deletions R/QueueClass.R
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,24 @@
#'
#' @author Simon Garnier, \email{garnier@@njit.edu}
#'
#' @seealso \code{\link{Image}}, \code{\link{Video}}, \code{\link{Stream}}
#' @seealso \code{\link{Video}}, \code{\link{Stream}}
#'
#' @export
"Queue"
setClass("Queue",
representation(
cpp = "C++Object"
),
prototype(
cpp = NULL
),
validity = function(object) {
if (is.null(object@cpp) || is(object@cpp, "Rcpp_Queue")) {
return(TRUE)
} else {
return(FALSE)
}
}
)


#' @title Create an Object of Class \code{Queue}
Expand Down
19 changes: 18 additions & 1 deletion R/StreamClass.R
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,25 @@
#' @slot release Function to release the object from memory.
#'
#' @author Simon Garnier, \email{garnier@@njit.edu}
#'
#' @seealso \code{\link{VideoWriter}}, \code{\link{Stream}}
#'
#' @export
"Stream"
setClass("Stream",
representation(
cpp = "C++Object"
),
prototype(
cpp = NULL
),
validity = function(object) {
if (is.null(object@cpp) || is(object@cpp, "Rcpp_Stream")) {
return(TRUE)
} else {
return(FALSE)
}
}
)


#' @title Create an Object of Class \code{Stream}
Expand Down
16 changes: 15 additions & 1 deletion R/VideoClass.R
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,21 @@
#' @author Simon Garnier, \email{garnier@@njit.edu}
#'
#' @export
"Video"
setClass("Video",
representation(
cpp = "C++Object"
),
prototype(
cpp = NULL
),
validity = function(object) {
if (is.null(object@cpp) || is(object@cpp, "Rcpp_Video")) {
return(TRUE)
} else {
return(FALSE)
}
}
)


#' @title Create an Object of Class \code{Video}
Expand Down
11 changes: 6 additions & 5 deletions R/VideoStackClass.R
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,12 @@
#'
#' @export
setClass("VideoStack",
contains = "list",
slots = c(nframes = "numeric"),
prototype = structure(
list(),
nframes = numeric())
contains = "list",
slots = c(nframes = "numeric"),
prototype = structure(
list(),
nframes = numeric()
)
)


Expand Down
17 changes: 16 additions & 1 deletion R/VideoWriterClass.R
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,23 @@
#' @slot release Function to release the object from memory.
#'
#' @author Simon Garnier, \email{garnier@@njit.edu}
#'
#' @export
"VideoWriter"
setClass("VideoWriter",
representation(
cpp = "C++Object"
),
prototype(
cpp = NULL
),
validity = function(object) {
if (is.null(object@cpp) || is(object@cpp, "Rcpp_VideoWriter")) {
return(TRUE)
} else {
return(FALSE)
}
}
)


#' @title Create an object of class \code{VideoWriter}
Expand Down
7 changes: 2 additions & 5 deletions R/zzz.R
Original file line number Diff line number Diff line change
@@ -1,18 +1,15 @@
#' @useDynLib Rvision, .registration = TRUE
#' @import Rcpp
#' @import methods
#' @importFrom graphics arrows par plot rasterImage points symbols
#' @importFrom stats median.default
#' @import pbapply
#' @import ROpenCVLite
#' @importFrom graphics arrows par plot rasterImage points symbols
#' @importFrom stats median.default
#' @importFrom grDevices col2rgb

### Load package module ###
Rcpp::loadModule("class_Image", TRUE)
Rcpp::loadModule("class_Capture", TRUE)
# Rcpp::loadModule("class_Video", TRUE)
# Rcpp::loadModule("class_BufferedVideo", TRUE)
# Rcpp::loadModule("class_Stream", TRUE)
Rcpp::loadModule("class_VideoWriter", TRUE)
Rcpp::loadModule("methods_Arithmetic", TRUE)
Rcpp::loadModule("methods_Statistics", TRUE)
Expand Down
2 changes: 1 addition & 1 deletion docs/pkgdown.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ articles:
z6_queue: z6_queue.html
z7_stack: z7_stack.html
z8_calib: z8_calib.html
last_built: 2024-01-30T00:47Z
last_built: 2024-01-30T15:18Z
urls:
reference: https://swarm-lab.github.io/Rvision/reference
article: https://swarm-lab.github.io/Rvision/articles
Expand Down
22 changes: 14 additions & 8 deletions docs/reference/CLAHE.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 6e77dbe

Please sign in to comment.