diff --git a/kernel/trunk/drivers/infinity.asm b/kernel/trunk/drivers/infinity.asm index 553afbe9b5..1cd4e92982 100644 --- a/kernel/trunk/drivers/infinity.asm +++ b/kernel/trunk/drivers/infinity.asm @@ -875,8 +875,8 @@ endp ; flags reserved -; RESET_INPUT equ 1 ;reserved reset and clear input buffer -; RESET_OUTPUT equ 2 ;reserved reset and clear output buffer +; RESET_INPUT equ 1 ;reset and clear input buffer +; RESET_OUTPUT equ 2 ;reset and clear output buffer ; RESET_ALL equ 3 @@ -913,6 +913,33 @@ proc ResetBuffer stdcall, str:dword, flags:dword mov [edx+STREAM.out_wp], ebx mov [edx+STREAM.out_rp], ebx mov [edx+STREAM.out_count], eax + + mov dword [edx+STREAM.time_base], eax + mov dword [edx+STREAM.time_base+4], eax + + mov dword [edx+STREAM.time_stamp], eax + mov dword [edx+STREAM.time_stamp+4], eax + mov dword [edx+STREAM.last_ts], eax + + + mov eax, [edx+STREAM.r_silence] + test [flags], 1 + jz @F + + mov ecx, [edx+STREAM.in_top] + mov edi, [edx+STREAM.in_base] + sub ecx, edi + shr ecx, 2 + cld + rep stosd +@@: + test [flags], 2 + jz @F + + mov edi, [edx+STREAM.out_base] + mov ecx, (64*1024)/4 + rep stosd +@@: ret .fail: or eax, -1 @@ -1153,8 +1180,6 @@ proc stop_buffer stdcall, str:dword mov [edx+STREAM.flags], SND_STOP -; stdcall [ServiceHandler], [hSound], dword DEV_STOP, 0 - mov eax, [edx+STREAM.notify_event] mov ebx, [edx+STREAM.notify_id] call ClearEvent ;eax ebx diff --git a/kernel/trunk/kernel.asm b/kernel/trunk/kernel.asm index ee36364cb9..2357748871 100644 --- a/kernel/trunk/kernel.asm +++ b/kernel/trunk/kernel.asm @@ -538,7 +538,7 @@ no_mode_0x12: mov ax, tss0 ltr ax - mov [LFBSize], 0x800000 + mov [LFBSize], 0xC00000 call init_LFB call init_fpu call init_malloc @@ -5128,7 +5128,7 @@ align 4 align 4 .no_put: pop ecx eax - + sub ebp, 4 dec ecx jnz .start_x @@ -5295,7 +5295,7 @@ set_screen: @@: call calculate_fast_getting_offset_for_WinMapAddress ; for Qemu or non standart video cards -; Unfortunately [BytesPerScanLine] does not always +; Unfortunately [BytesPerScanLine] does not always ; equal to [_display.width] * [ScreenBPP] / 8 call calculate_fast_getting_offset_for_LFB popad