mirror of
https://github.com/make-42/xyosc
synced 2024-11-22 17:20:09 +01:00
Compare commits
5 Commits
1a312e5e4a
...
9babdba06f
Author | SHA1 | Date | |
---|---|---|---|
|
9babdba06f | ||
|
61ab70dd2b | ||
|
da6f9141da | ||
|
7f8f57728a | ||
|
76bccc8a90 |
@ -1,2 +1,3 @@
|
||||
# xyosc
|
||||
A simple XY-oscilloscope written in Go.
|
||||
![Screenshot_20241021_143354-xyosc](https://github.com/user-attachments/assets/225dd213-5a26-4e99-ac2a-f2c69f1485e1)
|
||||
|
@ -16,7 +16,7 @@ var SampleSizeInBytes uint32
|
||||
const format = malgo.FormatF32
|
||||
|
||||
func Init() {
|
||||
SampleRingBuffer = ringbuffer.New(int(config.Config.RingBufferSize))
|
||||
SampleRingBuffer = ringbuffer.New(int(config.Config.RingBufferSize)).SetBlocking(true)
|
||||
SampleSizeInBytes = uint32(malgo.SampleSizeInBytes(format))
|
||||
}
|
||||
|
||||
|
@ -37,8 +37,8 @@ var DefaultConfig = ConfigS{
|
||||
WindowOpacity: 0.8,
|
||||
CaptureDeviceIndex: 0,
|
||||
SampleRate: 48000,
|
||||
RingBufferSize: 192000,
|
||||
ReadBufferSize: 192000,
|
||||
RingBufferSize: 4800,
|
||||
ReadBufferSize: 4800,
|
||||
Gain: 1,
|
||||
LineOpacity: 50,
|
||||
LineThickness: 2,
|
||||
|
3
main.go
3
main.go
@ -48,8 +48,9 @@ func main() {
|
||||
AX = BX
|
||||
AY = BY
|
||||
}
|
||||
//audio.SampleRingBuffer.Reset()
|
||||
if config.Config.FPSCounter {
|
||||
rl.DrawFPS(16, config.Config.WindowHeight)
|
||||
rl.DrawFPS(16, config.Config.WindowHeight-32)
|
||||
}
|
||||
rl.DrawTextEx(fonts.FontIosevka32, media.PlayingMediaInfo.Artist+" - "+media.PlayingMediaInfo.Title, rl.NewVector2(16, 16), 32, 2, config.AccentColor)
|
||||
rl.DrawTextEx(fonts.FontIosevka16, media.PlayingMediaInfo.Album, rl.NewVector2(16, 48), 16, 1, config.ThirdColor)
|
||||
|
5
wslbuild.sh
Executable file
5
wslbuild.sh
Executable file
@ -0,0 +1,5 @@
|
||||
sudo apt-get install gcc-multilib
|
||||
sudo apt-get install gcc-mingw-w64
|
||||
sudo apt-get install golang
|
||||
|
||||
GOOS=windows GOARCH=386 CGO_ENABLED=1 CXX=i686-w64-mingw32-g++ CC=i686-w64-mingw32-gcc go build -tags noaudio
|
Loading…
Reference in New Issue
Block a user