Skip to content
This repository has been archived by the owner on Mar 28, 2024. It is now read-only.

[BUG-214637] LSL Texture Baking #3341

Closed
1 task
sl-service-account opened this issue Feb 24, 2018 · 2 comments
Closed
1 task

[BUG-214637] LSL Texture Baking #3341

sl-service-account opened this issue Feb 24, 2018 · 2 comments

Comments

@sl-service-account
Copy link

sl-service-account commented Feb 24, 2018

How would you like the feature to work?

key llBakeTexture(integer width, integer height, list parameters);

Parameters are stackable:
Insert a image

[
    BAKE_TEXTURE_IMAGE,
    key Texture, //Base texture
]

Insert a alpha cutaway image(Similar to alpha masks)

[
    BAKE_TEXTURE_ALPHA,
    key Texture, //Alpha texture
]

Colourise the texture(Similar to: Similar to colouring a prim)

[
    BAKE_TEXTURE_TINT,
    vector Tint, //Tint(<1,1,1> for no tinting, <0,0,0> to make it fully black, <1,0,0> to make it tinted red)
]

Shift the hue of the texture(Similar to: Rainbow Colour in Skin editor)

[
    BAKE_TEXTURE_HUE,
    float Hue //0 for 0 hue shift. Question: Should max be 1, 360, or PI?
]

Stacking example:

[
    BAKE_TEXTURE_IMAGE, solid_white_texture, //Solid white background base
    BAKE_TEXTURE_TINT, <255,0,0>, //Colour the background red
    BAKE_TEXTURE_IMAGE, striped_black_texture //Overlay black stripes on it
]

This would result in a red and black striped texture.

Baked textures would be considered temporary assets and deleted when the script's context is destroyed, such as:

  • Prim is deleted or taken(NOT take copy)

  • Attachment is detached

  • Wearing avatar logs off

    To avoid giving pains to the texture baking service, the asset should not be destroyed when:

  • Avatar teleports or crosses sim

  • Object changes sim

    There should be a limit on how many bakes can be done per minute and per hour(EG: No more than 10 per minute and no more than 50 per hour, personally this seems more than a reasonable amount to me. This being per script) to prevent destruction of the asset server and texture baking service.

    Additionally, this will cause the script to sleep for somewhere between 1 to 5 seconds.

    Why is this feature important to you? How would it benefit the community?

    Honestly, I could have sworn this was suggested before, but I couldn't find it. I searched and searched but it was no where to be found.

    This would be useful to:

  • People who use mesh bodies and reduce polygon count as there would be no need for 8 layers of a mesh body stacked upon it's self to do "Tattoo layers" or "Clothing" layers.

  • The upcoming Animesh as it would provide the ability to create dynamic NPCs.

  • Furry and similar avatars as it would allow baking of marking and other layers while also colouring such layers with tint shifting

Links

Related

Original Jira Fields
Field Value
Issue BUG-214637
Summary LSL Texture Baking
Type New Feature Request
Priority Unset
Status Closed
Resolution Unactionable
Reporter Chaser Zaks (chaser.zaks)
Created at 2018-02-24T02:59:44Z
Updated at 2018-02-28T19:05:52Z
{
  'Business Unit': ['Platform'],
  'Date of First Response': '2018-02-24T08:09:42.697-0600',
  'How would you like the feature to work?': 'a',
  'ReOpened Count': 0.0,
  'Severity': 'Unset',
  'Target Viewer Version': 'viewer-development',
  'Why is this feature important to you? How would it benefit the community?': 'b',
}
@sl-service-account
Copy link
Author

Whirly Fizzle commented at 2018-02-24T14:09:43Z

Hiya Chaser,

LL have actually started work on the "Bakes on mesh" project.
See BUG-214631 & the repository is at https://bitbucket.org/anchor17/viewer-bakes-on-mesh

Best place to keep up to date on this project is the Content Creation User Group: http://wiki.secondlife.com/wiki/Content_Creation_User_Group

@sl-service-account
Copy link
Author

Kyle Linden commented at 2018-02-28T19:05:53Z

Hi Chaser,

Great suggestion. We already have a project underway!

Thanks!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant