How to transfer uint8 to int

guys, I read the color code of the picture through imgo :

height := imgo.GetImageHeight(img)       //   [height]
width := imgo.GetImageWidth(img)      //   [width]
imgMatrix := imgo.MustRead("F:\\GOPATH\\src\\code\\img\\hsq.jpg")
for starty := 0; starty < height; startyPP {
    for startx := 0; startx < width; startxPP {
        C := imgMatrix[starty][startx][0:3]
        R := imgMatrix[starty][startx][0] // R
        G := imgMatrix[starty][startx][1] // G
        B := imgMatrix[starty][startx][2] // B
    }
}

print out RCompGBank B and find that it is of uint8 type. I want to transfer it to int type and ask how to transfer it. Beginners ask for advice.

Jan.23,2022

The size of the

uint8 will not exceed the size of the int, direct cast.

package main

import "fmt"

func main() {
    var x uint8 = 255
    y := int(x)

    fmt.Println(y)
}

// 
//   go run x.go
// 255
MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1e5b5f6-65c3b.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1e5b5f6-65c3b.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?