国产 无码 综合区,色欲AV无码国产永久播放,无码天堂亚洲国产AV,国产日韩欧美女同一区二区

Python 一步一步教你用pyglet仿制鴻蒙系統(tǒng)里的時鐘

這篇具有很好參考價值的文章主要介紹了Python 一步一步教你用pyglet仿制鴻蒙系統(tǒng)里的時鐘。希望對大家有所幫助。如果存在錯誤或未考慮完全的地方,請大家不吝賜教,您也可以點(diǎn)擊"舉報違法"按鈕提交疑問。

Python 一步一步教你用pyglet仿制鴻蒙系統(tǒng)里的時鐘,Python,python,pyglet,harmonyos

目錄

鴻蒙時鐘

1. 繪制圓盤

2. 創(chuàng)建表類

3. 繪制刻度

4. 刻度數(shù)值

5. 添加指針

6. 轉(zhuǎn)動指針

7. 聯(lián)動時間

8. 時鐘走動


鴻蒙時鐘

本篇將用python pyglet庫復(fù)刻華為手機(jī)鴻蒙系統(tǒng)鬧鐘程序的時鐘,先在上圖中抓取出時分秒針及刻度、表盤的顏色RGB值:

bHour = (42, 43, 48, 255)
bMinute = (70, 71, 75, 255)
rSecond = (240, 70, 20, 255)
gScale = 215, 220, 230
wBackground = 248, 250, 252

1. 繪制圓盤

首先要畫一圓Circle,并用直線Line等分成60份。

? ? ? ? self.circle = pyglet.shapes.Circle(x, y, R, color=wBackground, batch=batch)
? ? ? ? self.scales = [pyglet.shapes.Line(x, y, x+R*cos(i*Pi/30), y+R*sin(i*Pi/30),
? ? ? ? ? ? ? ? ? ? ? ? ? ? width=2, color=gScales, batch=batch) for i in range(60)]

直線除圓心外的另一端點(diǎn)的坐標(biāo)計算公式,如下圖所示:

Python 一步一步教你用pyglet仿制鴻蒙系統(tǒng)里的時鐘,Python,python,pyglet,harmonyos

代碼:

import pyglet
from math import pi, sin, cos

window = pyglet.window.Window(800, 500, caption='圓盤')
pyglet.gl.glClearColor(1, 1, 1, 1)
batch = pyglet.graphics.Batch()

R = 200
wBackground = 248, 250, 252
gScales = 215, 220, 230

class Watch:
    def __init__(self, x, y):
        self.circle = pyglet.shapes.Circle(x, y, R, color=wBackground, batch=batch)
        self.scales = [pyglet.shapes.Line(x, y, x+R*cos(i*pi/30), y+R*sin(i*pi/30),
                            width=2, color=gScales, batch=batch) for i in range(60)]

@window.event
def on_draw():
    window.clear()
    batch.draw()

watch = Watch(window.width/2, window.height/2)

pyglet.app.run()

2. 創(chuàng)建表類

改造這個Watch類,可設(shè)置圓心和半徑,并讓它成為pyglet.window.Window的子類。

Python 一步一步教你用pyglet仿制鴻蒙系統(tǒng)里的時鐘,Python,python,pyglet,harmonyos

import pyglet
from math import sin, cos, pi

wBackground = (248, 250, 252, 255)
gScales = (215, 220, 230, 255)

class Watch(pyglet.window.Window):  
    def __init__(self, x, y, R=200, width=800, height=500, caption='圓盤'): 
        super().__init__(width, height, caption=caption)
        pyglet.gl.glClearColor(1, 1, 1, 1)
        self.batch = pyglet.graphics.Batch()
        self.circle = pyglet.shapes.Circle(x, y, R,  
                        color=wBackground, batch=self.batch)
        self.scales = [pyglet.shapes.Line(x, y, x+R*cos(i*pi/30), y+R*sin(i*pi/30),  
                        width=2, color=gScales, batch=self.batch) for i in range(60)]
    def on_draw(self):
        self.clear()
        self.batch.draw()
    def run(self):
        pyglet.app.run()

watch = Watch(500, 300, 150)
watch.run()

3. 繪制刻度

擴(kuò)大圓面并縮短和加粗直線,表盤和刻度的大致輪廓就出現(xiàn)了。

Python 一步一步教你用pyglet仿制鴻蒙系統(tǒng)里的時鐘,Python,python,pyglet,harmonyos

代碼:?

import pyglet
from math import sin, cos, pi

wBackground = (248, 250, 252, 255)
gScales = (215, 220, 230, 255)

class Watch(pyglet.window.Window):  
    def __init__(self, x, y, R=200, width=800, height=500, caption='刻度'): 
        super().__init__(width, height, caption=caption)
        pyglet.gl.glClearColor(1, 1, 1, 1)
        self.batch = pyglet.graphics.Batch()
        self.circle = pyglet.shapes.Circle(x, y, R*1.05,  
                        color=wBackground, batch=self.batch)
        self.scales = [pyglet.shapes.Line(x+R*cos(i*pi/30), y+R*sin(i*pi/30),
                        x+R*0.95*cos(i*pi/30), y+0.95*R*sin(i*pi/30),
                        width=3, color=gScales, batch=self.batch) for i in range(60)]
        for i, scale in enumerate(self.scales):
            if i%5==0:
                scale.width, scale.x2, scale.y2 = 5, x+R*0.92*cos(i*pi/30), y+0.92*R*sin(i*pi/30)
    def on_draw(self):
        self.clear()
        self.batch.draw()
    def run(self):
        pyglet.app.run()

watch = Watch(400, 250)
watch.run()

4. 刻度數(shù)值

在整點(diǎn)的刻度值邊上用標(biāo)簽標(biāo)注上1~12的數(shù)字。

self.labels = [pyglet.text.Label(str((2-i)%12+1), font_size=24, color=(0,0,0,255),
? ? ? ? ? ? ? ? ? ? ? ? x=x+R*0.82*cos(i*pi/6), y=y+0.82*R*sin(i*pi/6)+5, anchor_x='center',?
? ? ? ? ? ? ? ? ? ? ? ? anchor_y='center', batch=self.batch) for i in range(12)]

Python 一步一步教你用pyglet仿制鴻蒙系統(tǒng)里的時鐘,Python,python,pyglet,harmonyos

代碼:

import pyglet
from math import sin, cos, pi

wBackground = (248, 250, 252, 255)
gScales = (215, 220, 230, 255)
rSecond = (240, 70, 20, 255)

class Watch(pyglet.window.Window):  
    def __init__(self, x, y, R=200, width=800, height=500, caption='指針'): 
        super().__init__(width, height, caption=caption)
        pyglet.gl.glClearColor(1, 1, 1, 1)
        self.batch = pyglet.graphics.Batch()
        self.circle = pyglet.shapes.Circle(x, y, R*1.05, color=wBackground, batch=self.batch)
        self.scales = [pyglet.shapes.Line(x+R*cos(i*pi/30), y+R*sin(i*pi/30),
                        x+R*0.95*cos(i*pi/30), y+0.95*R*sin(i*pi/30),
                        width=3, color=gScales, batch=self.batch) for i in range(60)]
        for i,scale in enumerate(self.scales):
            if i%5==0:
                scale.width, scale.x2, scale.y2 = 5, x+R*0.92*cos(i*pi/30), y+0.92*R*sin(i*pi/30)
        self.labels = [pyglet.text.Label(str((2-i)%12+1), font_size=R*0.12, color=(0,0,0,255),
                        x=x+R*0.82*cos(i*pi/6), y=y+0.82*R*sin(i*pi/6)-R*0.06, anchor_x='center',
                        batch=self.batch) for i in range(12)]
    def on_draw(self):
        self.clear()
        self.batch.draw()
    def run(self):
        pyglet.app.run()

watch = Watch(400, 250)
watch.run()

5. 添加指針

時、分、秒針,用三個圓三條直線來表示。

? ? ? ? self.circle1 = pyglet.shapes.Circle(x, y, R*0.08, color=bHour)
? ? ? ? self.hour = pyglet.shapes.Line(x, y, x+R*0.7, y, width=9, color=bHour)
? ? ? ? self.minute = pyglet.shapes.Line(x, y, x+R*0.9, y, width=7, color=bMinute)
? ? ? ? self.second = pyglet.shapes.Line(x, y, x+R*1.1, y, width=5, color=rSecond)
? ? ? ? self.circle2 = pyglet.shapes.Circle(x, y, R*0.05, color=rSecond)
? ? ? ? self.circle3 = pyglet.shapes.Circle(x, y, R*0.02, color=wWhite)

不用擔(dān)心秒針長過表盤圓面,轉(zhuǎn)動前會作“移動”處理。

Python 一步一步教你用pyglet仿制鴻蒙系統(tǒng)里的時鐘,Python,python,pyglet,harmonyos

代碼:

import pyglet
from math import sin, cos, pi

wBackground = (248, 250, 252, 255)
gScales = (215, 220, 230, 255)
rSecond = (240, 70, 20, 255)
bMinute = (70, 71, 75, 255)
bHour   = (42, 43, 48, 255)
wWhite  = (255, 255, 255, 255)

class Watch(pyglet.window.Window):  
    def __init__(self, x, y, R=200, width=800, height=500, caption='指針'): 
        super().__init__(width, height, caption=caption)
        pyglet.gl.glClearColor(1, 1, 1, 1)
        self.batch = pyglet.graphics.Batch()
        self.circle = pyglet.shapes.Circle(x, y, R*1.05, color=wBackground, batch=self.batch)
        self.scales = [pyglet.shapes.Line(x+R*cos(i*pi/30), y+R*sin(i*pi/30),
                        x+R*0.95*cos(i*pi/30), y+0.95*R*sin(i*pi/30),
                        width=3, color=gScales, batch=self.batch) for i in range(60)]
        for i,scale in enumerate(self.scales):
            if i%5==0:
                scale.width, scale.x2, scale.y2 = 5, x+R*0.92*cos(i*pi/30), y+0.92*R*sin(i*pi/30)
        self.labels = [pyglet.text.Label(str((2-i)%12+1), font_size=R*0.12, color=(0,0,0,255),
                        x=x+R*0.82*cos(i*pi/6), y=y+0.82*R*sin(i*pi/6)-R*0.06, anchor_x='center',
                        batch=self.batch) for i in range(12)]
        self.circle1 = pyglet.shapes.Circle(x, y, R*0.08, color=bHour, batch=self.batch)
        self.hour = pyglet.shapes.Line(x, y, x+R*0.7, y, width=9, color=bHour, batch=self.batch)
        self.minute = pyglet.shapes.Line(x, y, x+R*0.9, y, width=7, color=bMinute, batch=self.batch)
        self.second = pyglet.shapes.Line(x, y, x+R*1.1, y, width=5, color=rSecond, batch=self.batch)
        self.circle2 = pyglet.shapes.Circle(x, y, R*0.05, color=rSecond, batch=self.batch)
        self.circle3 = pyglet.shapes.Circle(x, y, R*0.02, color=wWhite, batch=self.batch)
    def on_draw(self):
        self.clear()
        self.batch.draw()
    def run(self):
        pyglet.app.run()

watch = Watch(400, 250)
watch.run()

6. 轉(zhuǎn)動指針

時、分、秒針的轉(zhuǎn)動運(yùn)用Line控件的旋轉(zhuǎn)屬性.rotation,這種方法要比修改端點(diǎn)坐標(biāo)要方便。

默認(rèn)的旋轉(zhuǎn)中心是直線的左端點(diǎn),屬性.anchor_position可以修改中心坐標(biāo)。

? ? ? ? self.second.anchor_position = (R*0.1, 0)
? ? ? ? self.second.rotation = 210
? ? ? ? self.minute.rotation = 24
? ? ? ? self.hour.rotation = 160

Python 一步一步教你用pyglet仿制鴻蒙系統(tǒng)里的時鐘,Python,python,pyglet,harmonyos

代碼:

import pyglet
from math import sin, cos, pi

wBackground = (248, 250, 252, 255)
gScales = (215, 220, 230, 255)
rSecond = (240, 70, 20, 255)
bMinute = (70, 71, 75, 255)
bHour   = (42, 43, 48, 255)
wWhite  = (255, 255, 255, 255)

class Watch(pyglet.window.Window):  
    def __init__(self, x, y, R=200, width=800, height=500, caption='指針'): 
        super().__init__(width, height, caption=caption)
        pyglet.gl.glClearColor(1, 1, 1, 1)
        self.batch = pyglet.graphics.Batch()
        self.circle = pyglet.shapes.Circle(x, y, R*1.05, color=wBackground, batch=self.batch)
        self.scales = [pyglet.shapes.Line(x+R*cos(i*pi/30), y+R*sin(i*pi/30),
                        x+R*0.95*cos(i*pi/30), y+0.95*R*sin(i*pi/30),
                        width=3, color=gScales, batch=self.batch) for i in range(60)]
        for i,scale in enumerate(self.scales):
            if i%5==0:
                scale.width, scale.x2, scale.y2 = 5, x+R*0.92*cos(i*pi/30), y+0.92*R*sin(i*pi/30)
        self.labels = [pyglet.text.Label(str((2-i)%12+1), font_size=R*0.12, color=(0,0,0,255),
                        x=x+R*0.82*cos(i*pi/6), y=y+0.82*R*sin(i*pi/6)-R*0.06, anchor_x='center',
                        batch=self.batch) for i in range(12)]
        self.circle1 = pyglet.shapes.Circle(x, y, R*0.08, color=bHour, batch=self.batch)
        self.hour = pyglet.shapes.Line(x, y, x+R*0.7, y, width=9, color=bHour, batch=self.batch)
        self.minute = pyglet.shapes.Line(x, y, x+R*0.9, y, width=7, color=bMinute, batch=self.batch)
        self.second = pyglet.shapes.Line(x, y, x+R*1.1, y, width=5, color=rSecond, batch=self.batch)
        self.circle2 = pyglet.shapes.Circle(x, y, R*0.05, color=rSecond, batch=self.batch)
        self.circle3 = pyglet.shapes.Circle(x, y, R*0.02, color=wWhite, batch=self.batch)
        self.second.anchor_position = (R*0.1, 0)
        self.second.rotation = 210
        self.minute.rotation = 24
        self.hour.rotation = 160
    def on_draw(self):
        self.clear()
        self.batch.draw()
    def run(self):
        pyglet.app.run()

watch = Watch(400, 250)
watch.run()

7. 聯(lián)動時間

聯(lián)動系統(tǒng)時鐘,使用datetime.now()獲取當(dāng)前時間的時、分、秒的值。

? ? ? ? now = datetime.now()
? ? ? ? h, m, s = now.hour, now.minute, now.second
? ? ? ? self.second.rotation = -90 + s*6
? ? ? ? self.minute.rotation = -90 + m*6 + s/10
? ? ? ? self.hour.rotation = -90 + h%12*30 + m/2

Python 一步一步教你用pyglet仿制鴻蒙系統(tǒng)里的時鐘,Python,python,pyglet,harmonyos

代碼:

import pyglet
from math import sin, cos, pi
from datetime import datetime

wBackground = (248, 250, 252, 255)
gScales = (215, 220, 230, 255)
rSecond = (240, 70, 20, 255)
bMinute = (70, 71, 75, 255)
bHour   = (42, 43, 48, 255)
wWhite  = (255, 255, 255, 255)

class Watch(pyglet.window.Window):  
    def __init__(self, x, y, R=200, width=800, height=500, caption='指針'): 
        super().__init__(width, height, caption=caption)
        pyglet.gl.glClearColor(1, 1, 1, 1)
        self.batch = pyglet.graphics.Batch()
        self.circle = pyglet.shapes.Circle(x, y, R*1.05, color=wBackground, batch=self.batch)
        self.scales = [pyglet.shapes.Line(x+R*cos(i*pi/30), y+R*sin(i*pi/30),
                        x+R*0.95*cos(i*pi/30), y+0.95*R*sin(i*pi/30),
                        width=3, color=gScales, batch=self.batch) for i in range(60)]
        for i,scale in enumerate(self.scales):
            if i%5==0:
                scale.width, scale.x2, scale.y2 = 5, x+R*0.92*cos(i*pi/30), y+0.92*R*sin(i*pi/30)
        self.labels = [pyglet.text.Label(str((2-i)%12+1), font_size=R*0.12, color=(0,0,0,255),
                        x=x+R*0.82*cos(i*pi/6), y=y+0.82*R*sin(i*pi/6)-R*0.06, anchor_x='center',
                        batch=self.batch) for i in range(12)]
        self.circle1 = pyglet.shapes.Circle(x, y, R*0.08, color=bHour, batch=self.batch)
        self.hour = pyglet.shapes.Line(x, y, x+R*0.7, y, width=9, color=bHour, batch=self.batch)
        self.minute = pyglet.shapes.Line(x, y, x+R*0.9, y, width=7, color=bMinute, batch=self.batch)
        self.second = pyglet.shapes.Line(x, y, x+R*1.1, y, width=5, color=rSecond, batch=self.batch)
        self.circle2 = pyglet.shapes.Circle(x, y, R*0.05, color=rSecond, batch=self.batch)
        self.circle3 = pyglet.shapes.Circle(x, y, R*0.02, color=wWhite, batch=self.batch)
        self.second.anchor_position = (R*0.1, 0)
        self.update()
    def update(self):
        now = datetime.now()
        h, m, s = now.hour, now.minute, now.second
        self.second.rotation = -90 + s*6
        self.minute.rotation = -90 + m*6 + s/10
        self.hour.rotation = -90 + h%12*30 + m/2
    def on_draw(self):
        self.clear()
        self.batch.draw()
    def run(self):
        pyglet.app.run()

watch = Watch(400, 250)
watch.run()

8. 運(yùn)行時鐘

使用pyglet.clock.schedule_interval(self.update, 0.2)每秒更新5次。

總得來說,本次復(fù)刻比較完美,但直線控件在非水平或垂直狀態(tài),特別是小夾角時鋸齒很嚴(yán)重。

Python 一步一步教你用pyglet仿制鴻蒙系統(tǒng)里的時鐘,Python,python,pyglet,harmonyos

完整代碼:

import pyglet
from math import sin, cos, pi
from datetime import datetime

class Watch(pyglet.window.Window):  
    def __init__(self, x, y, R=200, width=800, height=500, caption='時鐘'): 
        super().__init__(width, height, caption=caption)
        wBackground = (248, 250, 252, 255)
        gScales = (215, 220, 230, 255)
        rSecond = (240, 70, 20, 255)
        bMinute = (70, 71, 75, 255)
        bHour   = (42, 43, 48, 255)
        wWhite  = (255, 255, 255, 255)
        pyglet.gl.glClearColor(1, 1, 1, 1)
        self.batch = pyglet.graphics.Batch()
        self.circle = pyglet.shapes.Circle(x, y, R*1.05, color=wBackground, batch=self.batch)
        self.scales = [pyglet.shapes.Line(x+R*cos(i*pi/30), y+R*sin(i*pi/30),
                        x+R*0.95*cos(i*pi/30), y+0.95*R*sin(i*pi/30),
                        width=3, color=gScales, batch=self.batch) for i in range(60)]
        for i,scale in enumerate(self.scales):
            if i%5==0:
                scale.width, scale.x2, scale.y2 = 5, x+R*0.92*cos(i*pi/30), y+0.92*R*sin(i*pi/30)
        self.labels = [pyglet.text.Label(str((2-i)%12+1), font_size=R*0.12, color=(0,0,0,255),
                        x=x+R*0.82*cos(i*pi/6), y=y+0.82*R*sin(i*pi/6)-R*0.06, anchor_x='center',
                        batch=self.batch) for i in range(12)]
        self.circle1 = pyglet.shapes.Circle(x, y, R*0.08, color=bHour, batch=self.batch)
        self.hour = pyglet.shapes.Line(x, y, x+R*0.7, y, width=9, color=bHour, batch=self.batch)
        self.minute = pyglet.shapes.Line(x, y, x+R*0.9, y, width=7, color=bMinute, batch=self.batch)
        self.second = pyglet.shapes.Line(x, y, x+R*1.1, y, width=5, color=rSecond, batch=self.batch)
        self.circle2 = pyglet.shapes.Circle(x, y, R*0.05, color=rSecond, batch=self.batch)
        self.circle3 = pyglet.shapes.Circle(x, y, R*0.02, color=wWhite, batch=self.batch)
        self.second.anchor_position = (R*0.1, 0)
        self.update(self.event)
        pyglet.clock.schedule_interval(self.update, 0.2)
    def update(self, event):
        now = datetime.now()
        h, m, s = now.hour, now.minute, now.second
        self.second.rotation = -90 + s*6
        self.minute.rotation = -90 + m*6 + s/10
        self.hour.rotation = -90 + h%12*30 + m/2
    def on_draw(self):
        self.clear()
        self.batch.draw()
    def run(self):
        pyglet.app.run()

watch = Watch(400, 250)
watch.run()

文章來源地址http://www.zghlxwxcb.cn/news/detail-838825.html

到了這里,關(guān)于Python 一步一步教你用pyglet仿制鴻蒙系統(tǒng)里的時鐘的文章就介紹完了。如果您還想了解更多內(nèi)容,請在右上角搜索TOY模板網(wǎng)以前的文章或繼續(xù)瀏覽下面的相關(guān)文章,希望大家以后多多支持TOY模板網(wǎng)!

本文來自互聯(lián)網(wǎng)用戶投稿,該文觀點(diǎn)僅代表作者本人,不代表本站立場。本站僅提供信息存儲空間服務(wù),不擁有所有權(quán),不承擔(dān)相關(guān)法律責(zé)任。如若轉(zhuǎn)載,請注明出處: 如若內(nèi)容造成侵權(quán)/違法違規(guī)/事實不符,請點(diǎn)擊違法舉報進(jìn)行投訴反饋,一經(jīng)查實,立即刪除!

領(lǐng)支付寶紅包贊助服務(wù)器費(fèi)用

相關(guān)文章

  • Python 一步一步教你用pyglet制作“彩色方塊連連看”游戲(續(xù))

    Python 一步一步教你用pyglet制作“彩色方塊連連看”游戲(續(xù))

    上期講到相同的色塊連接,鏈接見:?Python 一步一步教你用pyglet制作“彩色方塊連連看”游戲-CSDN博客 續(xù)上期,接下來要實現(xiàn)相鄰方塊的連線: 首先來進(jìn)一步擴(kuò)展 行列的類: class RC: ? ? def __init__(self, r=0, c=0): ? ? ? ? self.r, self.c = r, c ? ? def __repr__(self): ? ? ? ? return f\\\'Rc

    2024年04月08日
    瀏覽(25)
  • Python 一步一步教你用pyglet制作可播放音樂的揚(yáng)聲器類

    Python 一步一步教你用pyglet制作可播放音樂的揚(yáng)聲器類

    目錄 揚(yáng)聲器類 1. 繪制喇叭 2. 揚(yáng)聲器類 3. 禁音狀態(tài)? 4. 設(shè)置狀態(tài) 5. 切換狀態(tài) 6. 播放音樂 本篇將教你用pyglet畫一個小喇叭,如上圖。這里要用到pyglety庫shapes模塊中的圓弧Arc和多邊形Pylygon畫出這個揚(yáng)聲器的圖片: Arc(x, y, radius, segments=None, angle=6.283185307179586, start_angle=0, closed=

    2024年03月10日
    瀏覽(36)
  • FastAPI + NGINX + Gunicorn:一步一步教你部署一個高性能的Python網(wǎng)頁應(yīng)用

    FastAPI + NGINX + Gunicorn:一步一步教你部署一個高性能的Python網(wǎng)頁應(yīng)用

    部署一個 FastAPI 應(yīng)用到你的服務(wù)器是一項復(fù)雜的任務(wù)。如果你對 NGINX 、 Gunicorn 和 Uvicorn 這些技術(shù)不熟悉,可能會浪費(fèi)大量的時間。如果你是剛接觸 Python 語言不久或者希望利用 Python 構(gòu)建自己的Web應(yīng)用程序,本文的內(nèi)容可能會讓你第一次部署時更節(jié)省時間。 FastAPI 是用于開發(fā)

    2024年02月05日
    瀏覽(24)
  • Android一步一步教你實現(xiàn)Emoji表情鍵盤

    Android一步一步教你實現(xiàn)Emoji表情鍵盤

    背景: 說到聊天,就離不開文字、表情和圖片,表情和圖片增加了聊天的趣味性,讓原本無聊的文字瞬間用表情動了起來,今天給大家?guī)淼氖潜砬殒I盤,教你一步一步實現(xiàn),先來看下效果圖: 效果圖 功能: 1、如何控制表情鍵盤與輸入法的切換 2、如何解析表情 3、如何處

    2024年02月16日
    瀏覽(18)
  • GitHub入門指南:一步一步教你使用GitHub

    GitHub入門指南:一步一步教你使用GitHub

    引言: GitHub是一個流行的代碼托管平臺,它提供了強(qiáng)大的版本控制和協(xié)作功能,對于開發(fā)者來說是一個不可或缺的工具。本文將一步一步地教你如何使用GitHub,從注冊賬號到代碼同步,讓你能夠快速上手并充分利用這個平臺。 打開GitHub官網(wǎng)(github.com)。 點(diǎn)擊右上角的\\\"Sign

    2024年02月15日
    瀏覽(22)
  • Midjourney:一步一步教你如何使用 AI 繪畫 MJ

    Midjourney:一步一步教你如何使用 AI 繪畫 MJ

    一步一步如何使用 Midjourney 教程:教學(xué)怎么用 MJ? 原文:如何使用 Midjourney 教程 https://bysocket.com/saas-digital-marketing-channel/ Midjourney是一款使用文字描述來生成高質(zhì)量圖像的AI繪畫工具。這篇文章主要介紹了Midjourney及其用途,并針對Midjourney的使用提供了一些指南。該工具可以幫

    2023年04月21日
    瀏覽(25)
  • 文本轉(zhuǎn)語音-微軟Azure-一步一步教你從注冊到使用

    文本轉(zhuǎn)語音-微軟Azure-一步一步教你從注冊到使用

    牙叔教程 簡單易懂 他們的中文也許還行, 但是英文我試了都不滿意, 我再網(wǎng)上搜到的我認(rèn)為最好的是 但是丫真貴 Best Free Text To Speech Voice Reader | Speechify 現(xiàn)在的匯率是 139 × 6.91 = 960.49 一年一千塊, 好像還行哈, 但是沒卡呀, 擦, 比來比去, 還是微軟Azure性價比最高, 沒有微軟Azure的

    2024年02月07日
    瀏覽(27)
  • 一步一步教你如何使用 Visual Studio Code 編譯一段 C# 代碼

    一步一步教你如何使用 Visual Studio Code 編譯一段 C# 代碼

    以下是一步一步教你如何使用 Visual Studio Code 編寫使用 C# 語言輸出當(dāng)前日期和時間的代碼: 1、下載并安裝 .NET SDK。您可以從 Microsoft 官網(wǎng)下載并安裝它。 2、打開 Visual Studio Code,并安裝 C# 擴(kuò)展。您可以在 Visual Studio Code 中通過擴(kuò)展菜單安裝它。 3、打開 Visual Studio Code 中的文

    2024年02月11日
    瀏覽(34)
  • 【沐風(fēng)老師】一步一步教你在3dMax中進(jìn)行UVW貼圖和展開UVW的方法

    【沐風(fēng)老師】一步一步教你在3dMax中進(jìn)行UVW貼圖和展開UVW的方法

    將簡單或程序材質(zhì)應(yīng)用于對象并不難。但是當(dāng)表面需要在其上顯示某種紋理時,它會變得更加復(fù)雜。任何紋理貼圖都放在材質(zhì)的 Diffuse 插槽中,但渲染的結(jié)果可能無法預(yù)測。這就是為什么我們需要了解 3DMAX 如何將紋理應(yīng)用于 3D 對象,什么是 UVW 貼圖,以及為什么要“展開”它

    2024年02月04日
    瀏覽(23)
  • 一步一步教你如何白嫖谷歌云Google Cloud服務(wù)器$300美金羊毛

    一步一步教你如何白嫖谷歌云Google Cloud服務(wù)器$300美金羊毛

    我們都知道,Depay(現(xiàn)在改名為Dupay了)卡平??梢杂糜谖⑿?,支付寶,美團(tuán)消費(fèi),直接用USDT做日常小額消費(fèi),還免收手續(xù)費(fèi),小額的話,這點(diǎn)還是很舒服的。 但其實,Depay卡的用途遠(yuǎn)不止此,平??梢远嗤诰蛲诰?。今天教大家如何用Depay卡白嫖谷歌云服務(wù)器。申請成功后隨即可

    2024年02月04日
    瀏覽(33)

覺得文章有用就打賞一下文章作者

支付寶掃一掃打賞

博客贊助

微信掃一掃打賞

請作者喝杯咖啡吧~博客贊助

支付寶掃一掃領(lǐng)取紅包,優(yōu)惠每天領(lǐng)

二維碼1

領(lǐng)取紅包

二維碼2

領(lǐng)紅包