Skip to content

Instantly share code, notes, and snippets.

View Themaister's full-sized avatar

Hans-Kristian Arntzen Themaister

View GitHub Profile
vs.c: In function ‘roar_vs_ctl’:
vs.c:1692:8: error: ‘ROAR_VS_CMD_SET_ASYNC’ undeclared (first use in this function)
vs.c:1692:8: note: each undeclared identifier is reported only once for each function it appears in
vs.c:1695:8: error: ‘ROAR_VS_CMD_GET_ASYNC’ undeclared (first use in this function)
vs.c:1698:8: error: ‘ROAR_VS_CMD_LOCK_ASYNC’ undeclared (first use in this function)
vs.c:1706:8: error: ‘ROAR_VS_CMD_UNLOCK_ASYNC’ undeclared (first use in this function)
section .text
; Yay, we start off in 16-bit. Time for our journey to reach long-mode 64-bit.
[bits 16]
org 7c00h
jmp 0:start
start:
[bits 16]
org 7c00h
jmp 0:start
start:
xor ax, ax
mov ds, ax
mov eax, 80000000h
cpuid
org 7c00h
jmp 0:start
start:
xor ax, ax
mov ds, ax
mov eax, 80000000h
cpuid
cmp eax, 80000000h
jb no32
bSuccess = CreateProcessW(NULL,
wcmdline,
NULL,
NULL,
TRUE,
CREATE_NO_WINDOW,
NULL,
NULL,
&siStartInfo,
&piProcInfo);
int real_main(int argc, char *argv[]);
int main(int argc, char *argv[])
{
return real_main(argc, argv);
}
// ABI: fastcall
asm (
".text\n"
ASM_CO_SWAP_DEF
"movl %esp, (%edx) # Save stack pointer, and restore it again.\n"
"movl (%ecx), %esp\n"
"popl %eax\n"
"movl %ebp, 0x4(%edx) # Save non-volatile registers to buffer.\n"
"movl %esi, 0x8(%edx)\n"
roar_mus_t roar_vs_latency2(roar_vs_t * vss, int * error) {
check_async_latency(vss);
ssize_t pos = vss->writec - vss->last_server_pos;
ssize_t bps;
size_t lpos;
size_t lag;
bps = roar_info2samplesize(&(vss->info));
struct {
int lock;
float last_latency;
float last_time;
size_t written;
} latinfo;
static void audio_sample(uint16_t left, uint16_t right)
{
if ( !g_extern.audio_active )
return;
#ifdef HAVE_FFMPEG
if (g_extern.recording)
{
static int16_t static_data[2];
static_data[0] = left;