Tråd: Open AI
View Single Post
Meningsløst medlem
Quakecry's Avatar
Sitat av Dodecha Vis innlegg
Dette økte interessen min, har du noen eksempler her? Jeg er egentlig ikke så gira på å gi telefonnummeret mitt til tilfeldige firmaer på internett og endte med å avbryte registreringen.

Jeg sikter altså til om du har eksempler på hva du ba OpenAI gjøre og python koden som er kompatibel med blender.
Vis hele sitatet...
Siden han ikke svarte, jeg har ikke peiling på hverken python eller blender. Men her er hva GPT svarte når jeg spurte den om å lage en figur (freak figuren) som står i en foss mens fugler flyr ovenfor.

"Here is a sample code in Python that you can use in Blender to create the scene described:


Kanskje du klarer å lage noe mening ut av det, eller fortelle om det er et nogenlunde OK utgangspunkt.

Kode

import bpy

# Set the render resolution
bpy.context.scene.render.resolution_x = 1920
bpy.context.scene.render.resolution_y = 1080

# Add a plane for the ground
bpy.ops.mesh.primitive_plane_add(size=20, location=(0, 0, 0))

# Add a cube for the figure
bpy.ops.mesh.primitive_cube_add(size=1, location=(0, 0, 1))

# Add a cylinder for the waterfall
bpy.ops.mesh.primitive_cylinder_add(radius=5, depth=10, location=(-5, 0, 0))

# Add a series of particles to represent the birds
bpy.ops.mesh.primitive_uv_sphere_add(size=0.1, location=(5, 0, 5))
bpy.ops.object.particle_system_add()
bpy.context.object.particle_system.point_density_radius = 0.5
bpy.context.object.particle_system.settings.count = 1000

# Set the background image
bpy.context.scene.world.background_image = bpy.data.images.load("image_file.jpg")

# Animate the figure
bpy.context.object.animation_data_create()
bpy.context.object.animation_data.action = bpy.data.actions.new(name="Figure Action")

# Create a keyframe for the start of the animation
bpy.context.object.animation_data.action.fcurves.new(data_path="location", index=1)
bpy.context.object.animation_data.action.fcurves[0].keyframe_points.add(1)
bpy.context.object.animation_data.action.fcurves[0].keyframe_points[0].co = (0, 0, 1)
bpy.context.object.animation_data.action.fcurves[0].keyframe_points[0].interpolation = 'LINEAR'

# Create a keyframe for the end of the animation
bpy.context.object.animation_data.action.fcurves[0].keyframe_points.add(25)
bpy.context.object.animation_data.action.fcurves[0].keyframe_points[1].co = (0, 0, 2)
bpy.context.object.animation_data.action.fcurves[0].keyframe_points[1].interpolation = 'LINEAR'

# Render the animation
bpy.ops.render.render(animation=True)
"This code will create a plane for the ground, a cube for the figure, a cylinder for the waterfall, and a series of particles for the birds. It will also set the background image and animate the figure. Finally, it will render the animation.

Note that you will need to replace "image_file.jpg" with the actual file path to the background image you want to use. You will also need to adjust the size, location, and other properties of the objects to suit your desired scene."
Vis hele sitatet...