Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8270493
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T06:34:50+00:00 2026-06-08T06:34:50+00:00

Introduction I’m trying to emphase some region on a spherical surface saying that this

  • 0

Introduction

I’m trying to emphase some region on a spherical surface saying that this region should be colored as not transparent (alpha = 1.0) and other parts of the sphere should be colored as semi-transparent (alpha = 0.5).

Problem

Considering WAlpha(Data >= DummyValue) = 1.0 and WAlpha(Data < DummyValue) = 0.5, the following command does not work as expected:

surf(X, Y, Z, Data, 'AlphaData', WAlpha, 'FaceAlpha', 'interp');

It draws all non-selected region as fully-transparent:

Wrong transparency

Note

I have no issue when setting ‘FaceAlpha’ to scalar value (i.e its not an issue with my graphic card):

surf(X, Y, Z, Data, 'AlphaData', WAlpha, 'FaceAlpha', 0.5);

Semi transparent everywhere

Source code

Here is the link to the very short and dummy code I created to reproduce the issue: link

Please let me know if you have any other idea for emphasing selected region rather than using transparency.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-08T06:34:54+00:00Added an answer on June 8, 2026 at 6:34 am

    Here is quick test:

    %# surface data
    Z = membrane;
    
    %# alpha-transparency matrix
    A = ones(size(Z))*0.3;          %# transparent by default
    A(abs(Z)>0.5) = 1;              %# make certain region opaque
    
    %# plot
    figure('Renderer','opengl')
    surf(Z, 'AlphaData',A, 'AlphaDataMapping','none', ...
        'FaceAlpha','interp', 'EdgeColor','none')
    

    Result:

    screenshot

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Introduction I have some sort of values that I might want to access several
In Introduction to algorithms, 3rd edition exercise 24.3-5 wants an example that this is
Introduction I have a app that has multiple tables, some with and some without
Introduction : I have prior experience in programming (C, C++, Java), however, this is
Introduction I have been so annoyed by applications that have a startup dialog which
Introduction: Now I know this question could be very broad and it would be
Introduction: I'm trying to get additional fields to log with log4j, and its working
Introduction elem.hidden is a new property that allows to hide elements and detect whether
Introduction After watching this video from LIDNUG, about .NET code protection http://secureteam.net/lidnug_recording/Untitled.swf (especially from
Introduction Google chrome has a feature that allows you to create shortcuts to web

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.