-
-
Notifications
You must be signed in to change notification settings - Fork 428
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
867755e
commit a11bc18
Showing
2 changed files
with
38 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
bl_info = { | ||
"name": "Test Backend", | ||
"blender": (3, 1, 0), | ||
"category": "Paint", | ||
} | ||
|
||
import bpy | ||
from typing import List, Tuple | ||
from dream_textures.api import * | ||
|
||
class TestBackend(Backend): | ||
name = "Test" | ||
description = "A short description of this backend" | ||
|
||
custom_optimization: bpy.props.BoolProperty(name="My Custom Optimization") | ||
|
||
def list_models(self, context) -> List[Model]: | ||
return [] | ||
|
||
def list_schedulers(self, context) -> List[str]: | ||
return [] | ||
|
||
def generate(self, task: Task, model: Model, prompt: Prompt, size: Tuple[int, int] | None, seed: int, steps: int, guidance_scale: float, scheduler: str, seamless_axes: SeamlessAxes, step_preview_mode: StepPreviewMode, iterations: int, step_callback: StepCallback, callback: Callback): | ||
raise NotImplementedError() | ||
|
||
def draw_speed_optimizations(self, layout, context): | ||
layout.prop(self, "custom_optimization") | ||
|
||
def register(): | ||
bpy.utils.register_class(TestBackend) | ||
|
||
def unregister(): | ||
bpy.utils.unregister_class(TestBackend) |