How to use glTexStorage2D for pvr format?

This topic contains 2 replies, has 2 voices, and was last updated by  PaulL 2 years, 9 months ago.

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #31996

    Hi
    In this web site descripte that glTexStorage2D is like

    for (i = 0; i < levels; i++) {
    glTexImage2D(target, i, internalformat, width, height, 0, format, type, NULL);
    width = max(1, (width / 2));
    height = max(1, (height / 2));
    }
    But pvr format use glCompressedTexImage2D not glTexImage2D.

    If I know wroung or you know other function
    please let me know as soon as posible.

    #39519
    #39520

    PaulL
    Admin

    If I’m following correctly you’re looking for an API function similar to glTexStorage2D that maps a compressed texture?

    I’m not aware of one that exists, but you should be able to define your own using the snippet of code in that documentation page. It would look something like:

    for (i = 0; i < levels; i++) {
    glCompressedTexImage2D(target, i, internalformat, width, height, 0, format, type, NULL);
    width = max(1, (width / 2));
    height = max(1, (height / 2));
    }
Viewing 3 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic.