VTK官方例子

news2024/12/26 11:19:45

VTK官方例子

vtkMutableDirectedGraph

#!/usr/bin/env python

# noinspection PyUnresolvedReferences
import vtkmodules.vtkInteractionStyle
# noinspection PyUnresolvedReferences
import vtkmodules.vtkRenderingOpenGL2
from vtkmodules.vtkCommonColor import vtkNamedColors
from vtkmodules.vtkCommonCore import (
    vtkIntArray,
    vtkLookupTable
)
from vtkmodules.vtkCommonDataModel import vtkMutableDirectedGraph
from vtkmodules.vtkViewsCore import vtkViewTheme
from vtkmodules.vtkViewsInfovis import vtkGraphLayoutView


def main():
    colors = vtkNamedColors()

    graph = vtkMutableDirectedGraph()
    # Create a graph
    v1 = graph.AddVertex()
    v2 = graph.AddVertex()
    v3 = graph.AddVertex()

    graph.AddGraphEdge(v1, v2)
    graph.AddGraphEdge(v2, v3)

    # Create the color array
    edgeColors = vtkIntArray()
    edgeColors.SetNumberOfComponents(1)
    edgeColors.SetName('Color')

    lookupTable = vtkLookupTable()
    lookupTable.SetNumberOfTableValues(2)
    lookupTable.SetTableValue(0, colors.GetColor4d('Red'))
    lookupTable.SetTableValue(1, colors.GetColor4d('Lime'))
    lookupTable.Build()

    edgeColors.InsertNextValue(0)
    edgeColors.InsertNextValue(1)

    # Add the color array to the graph
    graph.GetEdgeData().AddArray(edgeColors)

    graphLayoutView = vtkGraphLayoutView()
    graphLayoutView.AddRepresentationFromInput(graph)
    graphLayoutView.SetLayoutStrategy('Simple 2D')
    graphLayoutView.GetLayoutStrategy().SetEdgeWeightField('Graphs')
    graphLayoutView.GetLayoutStrategy().SetWeightEdges(1)
    graphLayoutView.SetEdgeColorArrayName('Color')
    graphLayoutView.SetEdgeLabelVisibility(1)
    graphLayoutView.ColorEdgesOn()

    theme = vtkViewTheme()
    theme.SetCellLookupTable(lookupTable)

    graphLayoutView.ApplyViewTheme(theme)
    graphLayoutView.ResetCamera()
    graphLayoutView.GetRenderer().GetActiveCamera().Zoom(0.8)
    graphLayoutView.Render()
    graphLayoutView.GetLayoutStrategy().SetRandomSeed(0)
    graphLayoutView.GetInteractor().Initialize()
    graphLayoutView.GetInteractor().Start()


if __name__ == '__main__':
    main()

请添加图片描述

vtkGraphLayoutView

#!/usr/bin/env python

# noinspection PyUnresolvedReferences
import vtkmodules.vtkInteractionStyle
# noinspection PyUnresolvedReferences
import vtkmodules.vtkRenderingOpenGL2
from vtkmodules.vtkCommonColor import vtkNamedColors
from vtkmodules.vtkCommonCore import vtkIntArray
from vtkmodules.vtkCommonDataModel import vtkMutableDirectedGraph
from vtkmodules.vtkViewsInfovis import (
    vtkGraphLayoutView,
    vtkRenderedGraphRepresentation
)


def main():
    colors = vtkNamedColors()

    # Create a graph
    graph = vtkMutableDirectedGraph()

    v1 = graph.AddVertex()
    v2 = graph.AddVertex()
    graph.AddEdge(v1, v2)

    # Create an array for the vertex labels
    vertexIDs = vtkIntArray()
    vertexIDs.SetNumberOfComponents(1)
    vertexIDs.SetName('VertexIDs')

    # Set the vertex labels
    vertexIDs.InsertNextValue(0)
    vertexIDs.InsertNextValue(1)

    # Add the array to the graph
    graph.GetVertexData().AddArray(vertexIDs)

    graphLayoutView = vtkGraphLayoutView()
    graphLayoutView.AddRepresentationFromInput(graph)
    graphLayoutView.SetVertexLabelVisibility(1)

    rGraph = vtkRenderedGraphRepresentation()
    rGraph.SafeDownCast(graphLayoutView.GetRepresentation()).GetVertexLabelTextProperty().SetColor(
        colors.GetColor3d('Red'))
    graphLayoutView.SetLayoutStrategyToSimple2D()
    graphLayoutView.SetVertexLabelArrayName('VertexIDs')
    graphLayoutView.SetVertexLabelVisibility(True)
    graphLayoutView.ResetCamera()
    graphLayoutView.GetRenderer().GetActiveCamera().Zoom(0.8)
    graphLayoutView.Render()
    graphLayoutView.GetInteractor().Start()


if __name__ == '__main__':
    main()

在这里插入图片描述

ImageWeightedSum

#!/usr/bin/env python

# noinspection PyUnresolvedReferences
import vtkmodules.vtkInteractionStyle
# noinspection PyUnresolvedReferences
import vtkmodules.vtkRenderingOpenGL2
from vtkmodules.vtkCommonColor import vtkNamedColors
from vtkmodules.vtkImagingCore import vtkImageCast
from vtkmodules.vtkImagingMath import vtkImageWeightedSum
from vtkmodules.vtkImagingSources import (
    vtkImageMandelbrotSource,
    vtkImageSinusoidSource
)
from vtkmodules.vtkRenderingCore import (
    vtkImageActor,
    vtkRenderWindow,
    vtkRenderWindowInteractor,
    vtkRenderer
)


def main():
    colors = vtkNamedColors()

    # Create image 1
    source1 = vtkImageMandelbrotSource()
    source1.SetWholeExtent(0, 255, 0, 255, 0, 0)
    source1.Update()

    source1Double = vtkImageCast()
    source1Double.SetInputConnection(0, source1.GetOutputPort())
    source1Double.SetOutputScalarTypeToDouble()

    # Create image 2
    source2 = vtkImageSinusoidSource()
    source2.SetWholeExtent(0, 255, 0, 255, 0, 0)
    source2.Update()

    # Do the sum
    sumFilter = vtkImageWeightedSum()
    sumFilter.SetWeight(0, 0.8)
    sumFilter.SetWeight(1, 0.2)
    sumFilter.AddInputConnection(source1Double.GetOutputPort())
    sumFilter.AddInputConnection(source2.GetOutputPort())
    sumFilter.Update()

    # Display the images
    source1CastFilter = vtkImageCast()
    source1CastFilter.SetInputConnection(source1.GetOutputPort())
    source1CastFilter.SetOutputScalarTypeToUnsignedChar()
    source1CastFilter.Update()

    source2CastFilter = vtkImageCast()
    source2CastFilter.SetInputConnection(source2.GetOutputPort())
    source2CastFilter.SetOutputScalarTypeToUnsignedChar()
    source2CastFilter.Update()

    summedCastFilter = vtkImageCast()
    summedCastFilter.SetInputConnection(sumFilter.GetOutputPort())
    summedCastFilter.SetOutputScalarTypeToUnsignedChar()
    summedCastFilter.Update()

    # Create actors
    source1Actor = vtkImageActor()
    source1Actor.GetMapper().SetInputConnection(source1CastFilter.GetOutputPort())

    source2Actor = vtkImageActor()
    source2Actor.GetMapper().SetInputConnection(source2CastFilter.GetOutputPort())

    summedActor = vtkImageActor()
    summedActor.GetMapper().SetInputConnection(summedCastFilter.GetOutputPort())

    # There will be one render window
    renderWindow = vtkRenderWindow()
    renderWindow.SetSize(600, 300)

    # And one interactor
    interactor = vtkRenderWindowInteractor()
    interactor.SetRenderWindow(renderWindow)

    # Define viewport ranges
    # (xmin, ymin, xmax, ymax)
    leftViewport = [0.0, 0.0, 0.33, 1.0]
    centerViewport = [0.33, 0.0, .66, 1.0]
    rightViewport = [0.66, 0.0, 1.0, 1.0]

    # Setup renderers
    leftRenderer = vtkRenderer()
    renderWindow.AddRenderer(leftRenderer)
    leftRenderer.SetViewport(leftViewport)
    leftRenderer.SetBackground(colors.GetColor3d('Peru'))

    centerRenderer = vtkRenderer()
    renderWindow.AddRenderer(centerRenderer)
    centerRenderer.SetViewport(centerViewport)
    centerRenderer.SetBackground(colors.GetColor3d('DarkTurquoise'))

    rightRenderer = vtkRenderer()
    renderWindow.AddRenderer(rightRenderer)
    rightRenderer.SetViewport(rightViewport)
    rightRenderer.SetBackground(colors.GetColor3d('SteelBlue'))

    leftRenderer.AddActor(source1Actor)
    centerRenderer.AddActor(source2Actor)
    rightRenderer.AddActor(summedActor)

    leftRenderer.ResetCamera()
    centerRenderer.ResetCamera()
    rightRenderer.ResetCamera()

    renderWindow.SetWindowName('ImageWeightedSum')
    renderWindow.Render()
    interactor.Start()


if __name__ == '__main__':
    main()

请添加图片描述

writeImageData

#!/usr/bin/env python

# noinspection PyUnresolvedReferences
import vtkmodules.vtkInteractionStyle
# noinspection PyUnresolvedReferences
import vtkmodules.vtkRenderingOpenGL2
from vtkmodules.vtkCommonColor import vtkNamedColors
from vtkmodules.vtkCommonCore import VTK_DOUBLE
from vtkmodules.vtkCommonDataModel import vtkImageData
from vtkmodules.vtkFiltersGeometry import vtkImageDataGeometryFilter
from vtkmodules.vtkIOXML import (
    vtkXMLImageDataReader,
    vtkXMLImageDataWriter
)
from vtkmodules.vtkRenderingCore import (
    vtkActor,
    vtkPolyDataMapper,
    vtkRenderWindow,
    vtkRenderWindowInteractor,
    vtkRenderer
)


def get_program_parameters():
    import argparse
    description = 'Generate image data, edit data points, store and reload it.'
    epilogue = '''
   '''
    parser = argparse.ArgumentParser(description=description, epilog=epilogue)
    parser.add_argument('filename', help='A required vtk filename, e.g. writeImageData.vti.', nargs='?',
                        const='writeImageData.vti',
                        type=str, default='writeImageData.vti')
    args = parser.parse_args()
    return args.filename


def main():
    colors = vtkNamedColors()

    filename = get_program_parameters()

    imageData = vtkImageData()
    imageData.SetDimensions(3, 4, 5)
    imageData.AllocateScalars(VTK_DOUBLE, 1)

    dims = imageData.GetDimensions()

    # Fill every entry of the image data with '2.0'
    for z in range(dims[2]):
        for y in range(dims[1]):
            for x in range(dims[0]):
                imageData.SetScalarComponentFromDouble(x, y, z, 0, 2.0)

    writer = vtkXMLImageDataWriter()
    writer.SetFileName(filename)
    writer.SetInputData(imageData)
    writer.Write()

    # Read the file (to test that it was written correctly)
    reader = vtkXMLImageDataReader()
    reader.SetFileName(filename)
    reader.Update()

    # Convert the image to a polydata
    imageDataGeometryFilter = vtkImageDataGeometryFilter()
    imageDataGeometryFilter.SetInputConnection(reader.GetOutputPort())
    imageDataGeometryFilter.Update()

    mapper = vtkPolyDataMapper()
    mapper.SetInputConnection(imageDataGeometryFilter.GetOutputPort())

    actor = vtkActor()
    actor.SetMapper(mapper)
    actor.GetProperty().SetPointSize(3)

    # Setup rendering
    renderer = vtkRenderer()
    renderer.AddActor(actor)
    renderer.SetBackground(colors.GetColor3d('White'))
    renderer.ResetCamera()

    renderWindow = vtkRenderWindow()
    renderWindow.AddRenderer(renderer)

    renderWindowInteractor = vtkRenderWindowInteractor()

    renderWindowInteractor.SetRenderWindow(renderWindow)
    renderWindowInteractor.Initialize()
    renderWindowInteractor.Start()


if __name__ == '__main__':
    main()

EnhanceEdges

#!/usr/bin/env python

# noinspection PyUnresolvedReferences
import vtkmodules.vtkRenderingOpenGL2
from vtkmodules.vtkIOImage import vtkImageReader2Factory
from vtkmodules.vtkImagingColor import vtkImageMapToWindowLevelColors
from vtkmodules.vtkImagingCore import vtkImageCast
from vtkmodules.vtkImagingGeneral import vtkImageLaplacian
from vtkmodules.vtkImagingMath import vtkImageMathematics
from vtkmodules.vtkInteractionStyle import vtkInteractorStyleImage
from vtkmodules.vtkRenderingCore import (
    vtkImageActor,
    vtkRenderWindow,
    vtkRenderWindowInteractor,
    vtkRenderer
)


def main():
    # colors = vtkNamedColors()

    fileName = "D:/vtk/vtk-examples-master/src/Testing/Data/FullHead.mhd"

    # Read the image.
    readerFactory = vtkImageReader2Factory()
    reader = readerFactory.CreateImageReader2(fileName)
    reader.SetFileName(fileName)
    reader.Update()

    scalarRange = [0] * 2
    scalarRange[0] = reader.GetOutput().GetPointData().GetScalars().GetRange()[0]
    scalarRange[1] = reader.GetOutput().GetPointData().GetScalars().GetRange()[1]
    print("Range:", scalarRange)
    middleSlice = 22

    # Work with triple images.
    cast = vtkImageCast()
    cast.SetInputConnection(reader.GetOutputPort())
    cast.SetOutputScalarTypeToDouble()
    cast.Update()

    laplacian = vtkImageLaplacian()
    laplacian.SetInputConnection(cast.GetOutputPort())
    laplacian.SetDimensionality(3)

    enhance = vtkImageMathematics()
    enhance.SetInputConnection(0, cast.GetOutputPort())
    enhance.SetInputConnection(1, laplacian.GetOutputPort())
    enhance.SetOperationToSubtract()

    colorWindow = (scalarRange[1] - scalarRange[0])
    colorLevel = colorWindow / 2

    # Map the image through the lookup table.
    originalColor = vtkImageMapToWindowLevelColors()
    originalColor.SetWindow(colorWindow)
    originalColor.SetLevel(colorLevel)
    originalColor.SetInputConnection(reader.GetOutputPort())

    originalActor = vtkImageActor()
    originalActor.GetMapper().SetInputConnection(originalColor.GetOutputPort())
    originalActor.GetProperty().SetInterpolationTypeToNearest()
    originalActor.SetDisplayExtent(
        reader.GetDataExtent()[0], reader.GetDataExtent()[1],
        reader.GetDataExtent()[2], reader.GetDataExtent()[3],
        middleSlice, middleSlice)

    laplacianColor = vtkImageMapToWindowLevelColors()
    laplacianColor.SetWindow(1000)
    laplacianColor.SetLevel(0)
    laplacianColor.SetInputConnection(laplacian.GetOutputPort())

    laplacianActor = vtkImageActor()
    laplacianActor.GetMapper().SetInputConnection(laplacianColor.GetOutputPort())
    laplacianActor.GetProperty().SetInterpolationTypeToNearest()
    laplacianActor.SetDisplayExtent(originalActor.GetDisplayExtent())

    enhancedColor = vtkImageMapToWindowLevelColors()
    enhancedColor.SetWindow(colorWindow)
    enhancedColor.SetLevel(colorLevel)
    enhancedColor.SetInputConnection(enhance.GetOutputPort())

    enhancedActor = vtkImageActor()
    enhancedActor.GetMapper().SetInputConnection(enhancedColor.GetOutputPort())
    enhancedActor.GetProperty().SetInterpolationTypeToNearest()
    enhancedActor.SetDisplayExtent(originalActor.GetDisplayExtent())

    # Setup the renderers.
    originalRenderer = vtkRenderer()
    originalRenderer.AddActor(originalActor)
    laplacianRenderer = vtkRenderer()
    laplacianRenderer.AddActor(laplacianActor)
    enhancedRenderer = vtkRenderer()
    enhancedRenderer.AddActor(enhancedActor)

    renderers = list()
    renderers.append(originalRenderer)
    renderers.append(laplacianRenderer)
    renderers.append(enhancedRenderer)

    # Setup viewports for the renderers.
    rendererSize = 400
    xGridDimensions = 3
    yGridDimensions = 1

    renderWindow = vtkRenderWindow()
    renderWindow.SetSize(rendererSize * xGridDimensions, rendererSize * yGridDimensions)
    for row in range(0, yGridDimensions):
        for col in range(xGridDimensions):
            index = row * xGridDimensions + col
            # (xmin, ymin, xmax, ymax)
            viewport = [float(col) / xGridDimensions, float(yGridDimensions - (row + 1)) / yGridDimensions,
                        float(col + 1) / xGridDimensions, float(yGridDimensions - row) / yGridDimensions]
            renderers[index].SetViewport(viewport)
            renderWindow.AddRenderer(renderers[index])
    renderWindow.SetWindowName('EnhanceEdges')

    renderWindowInteractor = vtkRenderWindowInteractor()
    style = vtkInteractorStyleImage()

    renderWindowInteractor.SetInteractorStyle(style)
    renderWindowInteractor.SetRenderWindow(renderWindow)

    # Renderers share one camera.
    renderWindow.Render()
    renderers[0].GetActiveCamera().Dolly(1.5)
    renderers[0].ResetCameraClippingRange()

    for r in range(1, len(renderers)):
        renderers[r].SetActiveCamera(renderers[0].GetActiveCamera())
    renderWindowInteractor.Initialize()
    renderWindowInteractor.Start()


def get_program_parameters():
    import argparse
    description = 'High-pass filters can extract and enhance edges in an image.'
    epilogue = '''
    Subtraction of the Laplacian (middle) from the original image (left) results
     in edge enhancement or a sharpening operation (right).
    '''
    parser = argparse.ArgumentParser(description=description, epilog=epilogue,
                                     formatter_class=argparse.RawDescriptionHelpFormatter)
    parser.add_argument('filename', help='FullHead.mhd.')
    args = parser.parse_args()
    return args.filename


if __name__ == '__main__':
    main()

在这里插入图片描述

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.coloradmin.cn/o/1665676.html

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈,一经查实,立即删除!

相关文章

数组二叉树-华为OD

系列文章目录 文章目录 系列文章目录前言一、题目描述二、输入描述三、输出描述四、java代码五、测试用例 前言 本人最近再练习算法,所以会发布一些解题思路,希望大家多指教 一、题目描述 二叉树也可以用数组来存储,给定一个数组&#xff…

信息系统项目管理师0103:初步可行性研究(7项目立项管理—7.2项目可行性研究—7.2.2初步可行性研究)

点击查看专栏目录 文章目录 7.2.2初步可行性研究1.初步可行性研究定义2.辅助研究的目的和作用3.初步可行性研究的作用4.初步可行性研究的主要内容记忆要点总结7.2.2初步可行性研究 1.初步可行性研究定义 初步可行性研究一般是在对市场或者客户情况进行调查后,对项目进行的初步…

linux上使用mariadb安装mysql环境

之前都是手动安装mysql数据库,现在尝试下在线安装,为后面的项目部署做准备,突然发现使用mariadb安装mysql环境真的超级简单。 1.使用mariadb安装mysql 安装服务端: yum install mariadb-server -y 安装客户端: yum i…

大数据Scala教程从入门到精通第六篇:Scala编译结果反编译分析

一:Scala编译结果反编译分析 问题:为什么Scalac之后的生成的class文件有两个,一个带$的,一个不带$的? 不能直接java 执行scala编译的字节码文件。 直接运行的话就会报错,会报一个类没有被找到。 引入类库就…

【全面介绍下Spring】

🌈个人主页: 程序员不想敲代码啊 🏆CSDN优质创作者,CSDN实力新星,CSDN博客专家 👍点赞⭐评论⭐收藏 🤝希望本文对您有所裨益,如有不足之处,欢迎在评论区提出指正,让我们共…

Excel中实现md5加密

1.注意事项 (1)在Microsoft Excel上操作 (2)使用完,建议修改的配置全部还原,防止有风险。 2.准备MD5宏插件 MD5加密宏插件放置到F盘下(直接F盘下,不用放到具体某一个文件夹下) 提示:文件在文章顶部&…

JCR一区 | Matlab实现TTAO-CNN-BiLSTM-MATT多特征分类预测

JCR一区 | Matlab实现TTAO-CNN-BiLSTM-MATT多特征分类预测 目录 JCR一区 | Matlab实现TTAO-CNN-BiLSTM-MATT多特征分类预测分类效果基本介绍程序设计参考资料 分类效果 基本介绍 1.Matlab实现TTAO-CNN-BiLSTM-MATT三角拓扑聚合优化器优化双向长短期记忆神经网络融合多头注意力…

JAVA 标准接口返回与i18n国际化配置

不喜欢废话直接上代码 标准通用返回 package com.luojie.common;import com.luojie.common.inter.ResponseCommon; import lombok.Data;Data public class ResponseCommonImpl implements ResponseCommon {int code;String msg;Object entity; }package com.luojie.common;im…

苹果电脑MAC清理系统空间工具CleanMyMacX4.15.3中文版下载

苹果电脑以其出色的性能、优雅的设计和高效的操作系统而受到许多用户的喜爱。然而,随着时间的推移和使用量的增加,你可能会发现你的Mac开始变得缓慢和响应迟缓。这通常是因为硬盘空间被大量占用,影响了系统的整体性能。幸运的是,有…

白话机器学习4:小波分解的原理与Python代码实现

小波去噪可以想象成使用一把“筛子”来过滤信号。这个“筛子”能够根据信号的不同频率成分,将其分解成多个层次。在这个过程中,信号的重要信息通常包含在低频部分,而噪声则多分布在高频部分。 将信号通过这个“筛子”分解后,我们可…

基于Java+SpringBoot+Mybaties-plus+Vue+elememt 驾校管理 设计与实现

一.项目介绍 系统角色:管理员、驾校教练、学员 管理员: 个人中心:修改密码以及个人信息修改 学员管理:维护学员信息,维护学员成绩信息 驾校教练管理:驾校教练信息的维护 驾校车辆管理&…

线性集合:ArrayList,LinkedList,Vector/Stack

共同点:都是线性集合 ArrayList ArrayList 底层是基于数组实现的,并且实现了动态扩容(当需要添加新元素时,如果 elementData 数组已满,则会自动扩容,新的容量将是原来的 1.5 倍),来…

Python专题:八、列表(1)

Python的内置数据类型 数据类型:列表 list类型 可以是字符串,浮点数,整数,列表 列表特性 ①集合性的数据类型 ②列表是有序的 ③列表是可更新的 访问列表元素的方式也是[索引],也是从0开始的,不能超过…

eNSP中小型园区网络拓扑搭建(下)

→b站直通车,感谢大佬← →eNSP中小型园区网络拓扑搭建(上)← 不带配置命令的拓扑图已上传~ 配置ospf SW5 # ospf 1 router-id 5.5.5.5area 0.0.0.0network 192.168.51.5 0.0.0.0network 192.168.52.5 0.0.0.0area 0.0.0.10network 192.1…

泰迪智能科技大数据开发实训平台功能介绍

大数据开发实训平台是面向实训课和课后训练的编程实训平台,平台底层基于Docker技术,采用容器云部署方案,预装大数据相关课程教学所需的实训环境,拥有1主2从的Hadoop集群,还能够自主定制环境,并能够与实训管…

【C语言题解】用函数来模拟实现strlen()、strcpy()、strcmp()、strcat()

🥰欢迎关注 轻松拿捏C语言系列,来和 小哇 一起进步!✊ 学习了函数后,老师让我们用函数来实现上面这四个字符串函数。 我们首先来了解一下这四个字符串函数: 1.strlen函数 用于获取字符串长度(不包括末尾…

Excel 分组汇总后删除明细

有 Excel 数据如下所示: IDCriteria1Criteria2Criteria3Criteria4101210271239312381236123171826182918239182120182147 需要按 ID 分组汇总其余列,结果如下: IDCriteria1Criteria2Criteria3Criteria410121027123932561826939267 解法及简…

直播预告-如何快乐学习亚马逊云科技AWS,玩游戏备考亚马逊云科技云从业者认证?

一边玩一边学习亚马逊云科技云技能,这么好的事尊的假的?本周六(5约11日)晚20点,亚马逊云科技UG云端夜话Night Talk活动精彩回归~ 本次亚马逊云科技UG云端夜话直播是什么? 小李哥这次将在多平台…

2024版本idea集成SpringBoot + Ai 手写一个chatgpt 【推荐】

题目:SpringBoot OpenAi 在这里获取key和url:获取免费key base-url为这两个: 话不多说直接来! 一、简介 Spring AI 是 AI 工程的应用框架。其目标是将 Spring 生态系统设计原则(如可移植性和模块化设计&#xff…

音视频--AAC编码解析和示例

目录 1:AAC编码介绍 2:AAC格式介绍 3:AAC -ADTS帧组成 4:AAC-ADTS:(adts_fixed_header)格式介绍 5:AAC-ADTS:(adts_variable_header)格式介绍…