Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/TimvanScherpenzeel/spars
/ functions
Functions
170 in github.com/TimvanScherpenzeel/spars
⨍
Functions
170
◇
Types & classes
37
↓ 84 callers
Function
getParameter
( gl: WebGLRenderingContext | WebGL2RenderingContext, parameter: GLenum )
src/features/browserFeatures/getWebGLFeatures.ts:41
↓ 40 callers
Method
push
* Add an item to the tail of the internal list * * @param item Item to insert
src/dataStructures/Deque.ts:129
↓ 36 callers
Function
getShaderPrecisionFormat
( gl: WebGLRenderingContext | WebGL2RenderingContext, shaderType: GLenum, precisionType: GLenum )
src/features/browserFeatures/getWebGLFeatures.ts:53
↓ 27 callers
Method
toString
* Get the bitfield as a string representation
src/dataStructures/Bitfield.ts:85
↓ 25 callers
Function
getExtension
( gl: WebGLRenderingContext | WebGL2RenderingContext, extension: string )
src/features/browserFeatures/getWebGLFeatures.ts:65
↓ 23 callers
Method
unshift
* Add an item to the head of the internal list * * @param item Item to insert
src/dataStructures/Deque.ts:86
↓ 18 callers
Method
peekIndex
* Returns the item at the specified index from the internal list * You can specify a negative index to peek at values from the end of the internal
src/dataStructures/Deque.ts:43
↓ 18 callers
Method
set
* Set a bit index with value (positive number) * * 1 << 0 = 1 = 0b00000000000000000000000000000001 * 1 << 1 = 2 = 0
src/dataStructures/Bitfield.ts:53
↓ 17 callers
Method
get
* Get a bit value by index (positive number) * * @param index Index of bit
src/dataStructures/Bitfield.ts:35
↓ 16 callers
Function
assert
(condition: any, message: string)
src/utilities/assert.ts:10
↓ 15 callers
Method
pop
* Remove and return the last item on the internal list
src/dataStructures/Deque.ts:150
↓ 12 callers
Method
shift
* Remove and return the first item on the internal list
src/dataStructures/Deque.ts:106
↓ 11 callers
Method
when
(today: Date)
test/decorators/@Memoize.test.ts:15
↓ 10 callers
Method
toArray
* Get the internal list as array
src/dataStructures/Deque.ts:233
↓ 9 callers
Function
memoize
( fn: any, { size = 3, type = 'monadic', }: { size?: number; type?: 'monadic' | 'variadi
src/utilities/memoize.ts:111
↓ 8 callers
Function
canPlay
(type: HTMLAudioElement | HTMLVideoElement, mimeType: string)
src/features/browserFeatures/getMediaFeatures.ts:8
↓ 8 callers
Method
remove
* Remove and return the item at the specified index from the internal list * * @param index
src/dataStructures/Deque.ts:177
↓ 5 callers
Function
convertBlobToArrayBuffer
(blob: Blob)
src/utilities/convertBlobToArrayBuffer.ts:6
↓ 4 callers
Function
convertArrayBufferToBlob
(buffer: ArrayBuffer, type: string = '')
src/utilities/convertArrayBufferToBlob.ts:7
↓ 4 callers
Function
getUUID
()
src/utilities/getUUID.ts:45
↓ 4 callers
Method
getWorker
* Get an active thread by id * * @param id Id of the thread to get
src/threadPool/TaskManager.ts:262
↓ 4 callers
Method
peekHead
* Returns the head item of the internal list without removing it
src/dataStructures/Deque.ts:66
↓ 4 callers
Method
peekTail
* Returns the tail item of the internal list without removing it
src/dataStructures/Deque.ts:77
↓ 3 callers
Method
getSize
* Get the number of items in the internal list
src/dataStructures/Deque.ts:240
↓ 3 callers
Function
isAllowedAsKey
(key: any)
src/caching/PersistentCache.ts:15
↓ 3 callers
Method
isEmpty
* Check if the internal list is empty
src/dataStructures/Deque.ts:226
↓ 3 callers
Method
isEmpty
* Check if the linked list has no link nodes
src/frameScheduler/SinglyLinkedList.ts:55
↓ 3 callers
Method
pairIsInCorrectOrder
* Verify is a pair is ordered correctly * * @param firstElement First queue item * @param secondElement Second queue item
src/frameScheduler/PriorityUniqueQueue.ts:161
↓ 3 callers
Function
plugins
({ isUMD = false, isCJS = false, isES = false })
rollup.config.ts:18
↓ 2 callers
Method
addWorker
* Add a thread to the thread pool
src/threadPool/TaskManager.ts:273
↓ 2 callers
Method
copyList
* Copy the internal list to a new list * * @param shouldDoFullCopy Should it do a full copy
src/dataStructures/Deque.ts:273
↓ 2 callers
Function
createAudioContext
(desiredSampleRate = 44100)
src/audio/createAudioContext.ts:9
↓ 2 callers
Function
debounce
(func: any, wait: number, immediate: boolean = false)
src/utilities/debounce.ts:9
↓ 2 callers
Function
flushResultStatuses
()
src/threadPool/worklet.ts:199
↓ 2 callers
Method
get
* Get a cache entry from the cache by key * * @param key Key to get cache entry by
src/utilities/memoize.ts:28
↓ 2 callers
Function
getCookie
(key: string)
src/cookies/index.ts:36
↓ 2 callers
Function
getRandomValues
()
src/utilities/getUUID.ts:7
↓ 2 callers
Method
growList
* Double the length of the internal list
src/dataStructures/Deque.ts:255
↓ 2 callers
Function
next
()
src/threadPool/worklet.ts:122
↓ 2 callers
Method
push
* Push a list node at the tail of the linked list * * @param data Data to add to the list node
src/frameScheduler/SinglyLinkedList.ts:22
↓ 2 callers
Function
runDefer
()
src/frameScheduler/index.ts:30
↓ 2 callers
Method
set
* Set a cache entry by key * * @param key Key to set cache entry by * @param value Value to set cache entry to
src/utilities/memoize.ts:38
↓ 2 callers
Method
shrinkList
* Shrink the internal list
src/dataStructures/Deque.ts:300
↓ 2 callers
Method
swap
* Swap the pointer to the item in the heap * * @param indexA First index * @param indexB Second index
src/frameScheduler/PriorityUniqueQueue.ts:171
↓ 2 callers
Function
walk
(obj: any[], action: (value: Task, i: string, obj: any[]) => void)
src/threadPool/worklet.ts:56
↓ 2 callers
Function
walkReduce
( obj: any, reducer: any, accumulator?: any, index?: any, pa
src/threadPool/worklet.ts:33
↓ 1 callers
Function
Memoize
()
src/decorators/@Memoize.ts:8
↓ 1 callers
Method
add
* Add a queue item to the priority queue * * @param priority Priority of the queue item * @param value Task to store
src/frameScheduler/PriorityUniqueQueue.ts:66
↓ 1 callers
Function
addTask
(callback: () => void, priority: number)
src/frameScheduler/index.ts:43
↓ 1 callers
Method
addWorklet
* Add a compute module to the task pool * * @param code Compute module source code
src/threadPool/TaskManager.ts:147
↓ 1 callers
Function
callback
()
src/analytics/index.ts:106
↓ 1 callers
Method
cancelTask
* Cancel a task * * Cancellation isn't guaranteed, however cancellation of a task * known to have been already completed will return `false`.
src/threadPool/TaskManager.ts:161
↓ 1 callers
Function
checkAutoplay
(element?: HTMLElement)
src/audio/checkAutoplay.ts:31
↓ 1 callers
Function
createFrameScheduler
()
src/frameScheduler/index.ts:26
↓ 1 callers
Method
delete
* Delete a { key: value } pair by key in the persistent cache * * @param key Key of cache entry to delete
src/caching/PersistentCache.ts:123
↓ 1 callers
Function
deleteCookie
( key: string, path: string = '/', domain: string = window.location.hostname.replace('www.', '') )
src/cookies/index.ts:72
↓ 1 callers
Method
dispose
* Dispose all active threads
src/threadPool/index.ts:61
↓ 1 callers
Function
easeInCubic
( time: number, beginValue: number, changeInValue: number, duration: number )
src/easings/index.ts:66
↓ 1 callers
Function
easeInOutCubic
( time: number, beginValue: number, changeInValue: number, duration: number )
src/easings/index.ts:100
↓ 1 callers
Function
easeOutCubic
( time: number, beginValue: number, changeInValue: number, duration: number )
src/easings/index.ts:83
↓ 1 callers
Method
exec
* Execute a task * * @param task Task to execute * @param taskName Name of the task to execute * @param args Any arguments that have been
src/threadPool/TaskManager.ts:57
↓ 1 callers
Function
extractVersion
(uuid: string)
test/utilities/getUUID.test.ts:8
↓ 1 callers
Method
freeWorkerTask
* Mark a thread as free for new computation * * @param worker Thread to mark as free
src/threadPool/TaskManager.ts:248
↓ 1 callers
Function
get
()
src/threadPool/Task.ts:33
↓ 1 callers
Method
get
* Get a priority slot * * @param priority Priority slot
src/frameScheduler/PriorityUniqueQueue.ts:84
↓ 1 callers
Method
getNextWorker
* If no suitable worker for the task was found get the next available one
src/threadPool/TaskManager.ts:378
↓ 1 callers
Function
getOrientation
()
src/events/onOrientationChange.ts:12
↓ 1 callers
Method
getTaskDependencies
* Get and collect any dependencies of a task * * @param args Task dependencies
src/threadPool/TaskManager.ts:338
↓ 1 callers
Method
getTaskResult
* Get a task result * * @param taskId Id of task to get result of
src/threadPool/TaskManager.ts:187
↓ 1 callers
Method
getTaskWorker
* Get the most suitable worker for this task (keep dependencies in mind) * * @param taskName Name of the task * @param args Any arguments tha
src/threadPool/TaskManager.ts:354
↓ 1 callers
Method
getWorkerForTask
* Get the most suitable worker for this task (keep dependencies in mind) * * @param taskId Id of the task
src/threadPool/TaskManager.ts:323
↓ 1 callers
Function
newFunction
(name: string, fn: () => any)
src/decorators/@Memoize.ts:25
↓ 1 callers
Function
newGetter
(name: string, fn: () => any)
src/decorators/@Memoize.ts:36
↓ 1 callers
Method
on
* Start the frame ticker
src/frameTicker/index.ts:36
↓ 1 callers
Method
peek
* Peek at the heap container head node
src/frameScheduler/PriorityUniqueQueue.ts:35
↓ 1 callers
Method
poll
* Poll the heap container for the next queue item in the heap container
src/frameScheduler/PriorityUniqueQueue.ts:42
↓ 1 callers
Method
process
()
src/threadPool/TaskManager.ts:296
↓ 1 callers
Method
pushDown
* Push a queue item down the heap
src/frameScheduler/PriorityUniqueQueue.ts:127
↓ 1 callers
Method
pushUp
* Push a queue item up the heap
src/frameScheduler/PriorityUniqueQueue.ts:109
↓ 1 callers
Function
realm
(code: string, scope: any)
src/threadPool/worklet.ts:13
↓ 1 callers
Method
resize
* Resize the bitfield * * @param size New size of the bitfield
src/dataStructures/Bitfield.ts:72
↓ 1 callers
Method
rising
* Move the priority pointer
src/frameScheduler/PriorityUniqueQueue.ts:91
↓ 1 callers
Function
scroll
()
src/scrolling/scrollTo.ts:46
↓ 1 callers
Function
setCookie
( key: string, value: string, expiryDays: number = 365, path: string = '/', domain: string = window.
src/cookies/index.ts:13
↓ 1 callers
Method
shift
* Shift a list node off of the head of the linked list
src/frameScheduler/SinglyLinkedList.ts:42
↓ 1 callers
Function
value
()
src/threadPool/Task.ts:47
↓ 1 callers
Function
vanillaFibonacci
(n: number)
test/utilities/memoize.test.ts:10
Function
$$TASK_WORKLET_WAIT
(promise: Promise<any>)
src/threadPool/worklet.ts:283
Function
$$cancel
(id: number)
src/threadPool/worklet.ts:330
Function
$$eval
(code: string)
src/threadPool/worklet.ts:279
Function
$$getResult
(id: number)
src/threadPool/worklet.ts:311
Function
$$init
(identifier: string, worklets: string[])
src/threadPool/worklet.ts:273
Function
$$task
(id: number)
src/threadPool/worklet.ts:298
Method
add
* Add a compute module to the task pool * * @param moduleName Name of the compute module to make available to the task * @param moduleClass C
src/threadPool/index.ts:52
Function
addition
(numb: number)
test/utilities/memoize.test.ts:33
Method
clear
* Clear the entire persistent cache from { key: value } pairs
src/caching/PersistentCache.ts:136
Function
collectTransferrables
(transfer: any[], value: any)
src/threadPool/worklet.ts:72
Method
constructor
* Optionally populate the internal list with an array * * @param array Array with items to initialise the internal list with
src/dataStructures/Deque.ts:29
Method
constructor
* Set the size of the bitfield and initializes the internal data buffer * * @param size Size of the bitfield
src/dataStructures/Bitfield.ts:25
Method
constructor
* Upon initial load check the cookies for the audio manager configuration
src/audio/audioManager.ts:24
next →
1–100 of 170, ranked by callers